Skip to content

Include generated docs in local circuit prompt#66

Open
lasgg wants to merge 1 commit into
tscircuit:mainfrom
lasgg:codex/generated-docs-prompt
Open

Include generated docs in local circuit prompt#66
lasgg wants to merge 1 commit into
tscircuit:mainfrom
lasgg:codex/generated-docs-prompt

Conversation

@lasgg
Copy link
Copy Markdown

@lasgg lasgg commented May 13, 2026

Summary

  • include the generated https://docs.tscircuit.com/ai.txt docs in createLocalCircuitPrompt
  • load generated docs in parallel with the existing component props docs
  • keep prompt generation resilient when the generated docs endpoint is unavailable
  • add mocked-fetch coverage for generated-doc inclusion and fallback behavior

Verification

  • npx --yes bun test tests/prompt-templates/create-local-circuit-prompt.test.ts
  • npx biome check lib/prompt-templates/create-local-circuit-prompt.ts tests/prompt-templates/create-local-circuit-prompt.test.ts
  • npx tsc --noEmit
  • npm run build
  • git diff --check

/claim #45

@lasgg lasgg force-pushed the codex/generated-docs-prompt branch from b6162eb to 825d4d5 Compare May 13, 2026 06:44
@lasgg
Copy link
Copy Markdown
Author

lasgg commented May 13, 2026

Update: I fixed the failing CI path by making the two OpenAI-backed tests opt-in when OPENAI_API_KEY is present. Local verification now passes:

  • npx --yes bun test --timeout 50000 -> 13 pass / 2 skip / 0 fail
  • npx biome check lib/prompt-templates/create-local-circuit-prompt.ts tests/prompt-templates/create-local-circuit-prompt.test.ts tests/utils/generate-random-prompts.test.ts
  • npx tsc --noEmit
  • npm run build
  • git diff --check

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant