Skip to content

Add chat story context and AI response enhancements - #8

Merged
brianlovin merged 2 commits into
mainfrom
brianlovin/chat-story-context
Jan 26, 2026
Merged

Add chat story context and AI response enhancements#8
brianlovin merged 2 commits into
mainfrom
brianlovin/chat-story-context

Conversation

@brianlovin

Copy link
Copy Markdown
Owner

Summary

  • Add typing indicator animation while streaming AI responses
  • Integrate web search for both Anthropic and OpenAI to fetch article content
  • Improve story context formatting to distinguish between story and HN discussion
  • Optimize costs by using cheaper models for auxiliary tasks
  • Preserve chat messages when toggling settings, and include tests for buildStoryContext

Test plan

  • Run bun run test - all tests pass
  • Run bun run typecheck - no type errors
  • Test chat with story: verify typing indicator shows and then AI response appears
  • Toggle settings while chat is visible: verify chat messages are preserved
  • Test that web search is used when available (logs will show "Using Responses API stream with web_search")

🤖 Generated with Claude Code

brianlovin and others added 2 commits January 25, 2026 19:33
- Add typing indicator animation while streaming AI responses
- Integrate web search for both Anthropic and OpenAI to fetch article content
- Improve story context formatting to distinguish between story and HN discussion
- Optimize costs by using cheaper models for suggestions and follow-up questions
- Preserve chat messages when toggling settings view
- Fix bug where typing indicator could be left running if selected post was null
- Add tests for buildStoryContext
- Improve error logging for OpenAI Responses API fallback

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
Resolved conflict by combining:
- Chat input blur when entering settings (from feature branch)
- SavedChatSessions persistence mechanism (from main)
@brianlovin
brianlovin merged commit b0b8b7a into main Jan 26, 2026
1 check passed
@brianlovin
brianlovin deleted the brianlovin/chat-story-context branch January 26, 2026 03:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant