claude-chat
Interactive chat panel for Claude Code
asiloisad 85 0 0.11.0 MIT GitHub
  • Made for Pulsar!

    This package was written specifically for Pulsar and did not exist in the Atom package repository.

claude-chat

Interactive chat panel for Claude Code. Provides a conversational interface with streaming responses, markdown rendering, and session management.

panel-1

panel-2

Features

  • Streaming responses: Real-time text display as Claude responds.
  • Markdown rendering: Full markdown support with syntax-highlighted code blocks using tree-sitter grammars matching your editor theme.
  • Tool visualization: Rich display of tool calls (Read, Write, Edit, Bash, Glob, Grep, Task, etc.) with collapsible details, diffs, search results, and inline previews.
  • Interactive permissions: Allow/Deny prompts with "Always Allow" and permission mode suggestions. AskUserQuestion prompts render as interactive option cards with multi-question support.
  • Clean interrupts: Stop button sends interrupt signal for graceful abort instead of killing the process.
  • Session persistence: Conversations are saved and can be resumed across restarts.
  • Chat history: Browse and revisit previous sessions.
  • Context attachments: Attach selections, files, images, or tree-view paths to prompts.
  • Permission modes: Switch between Default, Plan, Accept Edits, and Bypass modes via keyboard shortcuts.
  • LaTeX rendering: Math expressions rendered via MathJax.
  • pulsar-mcp: Auto-connects MCP server for editor tool integration.

Installation

To install claude-chat search for claude-chat in the Install pane of the Pulsar settings or run ppm install claude-chat. Alternatively, you can run ppm install asiloisad/pulsar-claude-chat to install a package directly from the GitHub repository.

Commands

Commands available in atom-workspace:

  • claude-chat:open: open chat panel,
  • claude-chat:toggle: toggle chat panel,
  • claude-chat:new-chat: start a new chat session,
  • claude-chat:open-latest: open the most recent session,
  • claude-chat:settings: open package settings.

Commands available in atom-text-editor:not([mini]):

  • editor:attach-to-claude: attach current selection to chat context.

Commands available in .tree-view:

  • tree-view:attach-to-claude: attach selected files to chat context.

Commands available in the prompt editor:

  • claude-chat:send: send the current prompt,
  • claude-chat:stop: stop the current response,
  • claude-chat:clear-prompt: clear the prompt editor,
  • claude-chat:scroll-up: scroll chat output up,
  • claude-chat:scroll-down: scroll chat output down,
  • claude-chat:show-usage: show token usage,
  • claude-chat:focus-active-editor: focus the active text editor.

Commands available in .claude-chat:

  • claude-chat:copy: copy selected text,
  • claude-chat:copy-message: copy full message,
  • claude-chat:unfold-all: expand all tool call details,
  • claude-chat:fold-all: collapse all tool call details,
  • claude-chat:clear-messages: clear all messages.

Custom Provider

You can use any OpenAI-compatible API provider (Ollama, LM Studio, OpenRouter, etc.) by configuring the following settings:

  1. Set Model to custom and enter the model name in Custom Model (e.g. qwen3-coder).
  2. Set Custom API Base URL to the provider endpoint (e.g. http://localhost:11434 for Ollama).

For providers that require an API key, set the ANTHROPIC_API_KEY environment variable in your shell before launching Pulsar. For Ollama and other local providers, no API key is needed.

Chat history

Chat sessions are stored in ~/.pulsar/claude-chat-sessions/ directory. Each session is saved as a JSON file containing messages, timestamps, project paths, and token usage.

Provided Service claude-chat

Allows other packages to send prompts, attach context, and receive messages programmatically.

In your package.json:

{
  "consumedServices": {
    "claude-chat": {
      "versions": { "^1.0.0": "consumeClaudeChat" }
    }
  }
}

In your main module:

module.exports = {
  consumeClaudeChat(service) {
    this.claudeChat = service;
  }
}

sendPrompt(text, options)

Send a prompt to Claude programmatically.

// Simple prompt
await service.sendPrompt("Explain this code");

// With attach context (supports multi-cursor selections)
await service.sendPrompt("Review this selection", {
  attachContext: {
    type: "selections",
    path: "src/app.js",
    line: 42,
    selections: [
      { text: "const foo = bar()", range: { start: { row: 41, column: 0 }, end: { row: 41, column: 18 } } }
    ],
    label: "src/app.js:42",
    icon: "code"
  }
});

// Without focusing the panel
await service.sendPrompt("Run tests", { focus: false });

Options:

  • attachContext - Context to attach (selection, paths, position, image)
  • focus - Whether to focus the panel after sending (default: true)

Returns: Promise<boolean> - Whether the message was sent successfully.

setAttachContext(context)

Set the attach context without sending a message.

service.setAttachContext({
  type: "paths",
  paths: ["relative/path/to/file.js"],
  label: "file.js",
  icon: "file"
});

Context types:

  • paths - File or directory paths
  • selections - Selections/cursors with path, line, selections array (empty text = cursor position)
  • image - Image file with optional region selection

clearAttachContext()

Clear the current attach context.

hasPanel()

Check if the chat panel exists. Returns boolean.

onDidReceiveMessage(callback)

Subscribe to receive messages from Claude.

const disposable = service.onDidReceiveMessage((message) => {
  console.log("Claude responded:", message.content);
  if (message.thinking) {
    console.log("Thinking:", message.thinking);
  }
});

// Later, to unsubscribe:
disposable.dispose();

Message object:

  • role - Always "assistant"
  • content - The response text
  • thinking - Extended thinking content (if enabled)

Consumed Service pulsar-mcp

Auto-connects the pulsar-mcp MCP server when starting a Claude session. When the service is available, the bridge port and server path are passed to the Claude CLI via --mcp-config, giving Claude direct access to editor tools (read/write text, open files, manage selections, etc.).

Consumed Service tree-view

Reads selected file and folder paths from tree-view-plus. Used by the tree-view:attach-to-claude command to attach selected entries as context for the chat prompt.

Contributing

Got ideas to make this package better, found a bug, or want to help add new features? Just drop your thoughts on GitHub — any feedback's welcome!