CodeWiki icon indicating copy to clipboard operation
CodeWiki copied to clipboard

met failed when running "codewiki generate"

Open yichinwang opened this issue 1 year ago • 5 comments

[1/5] Dependency Analysis [2/5] Module Clustering [3/5] Documentation Generation [23:17:21] ERROR Error processing module claude-agent-desktop: All models from FallbackModel failed (2 sub-exceptions) ✗ Documentation generation failed: All models from FallbackModel failed (2 sub-exceptions)

yichinwang avatar Nov 24 '25 16:11 yichinwang

Could you please provide detailed logs when you run codewiki config validate? It appears that your configuration may be invalid, which could be causing the LLM call to fail.

anhnh2002 avatar Nov 25 '25 03:11 anhnh2002

CodeWiki Configuration ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Credentials API Key: sk-a...XQAA (in system keychain)

API Settings Base URL: https://api.anthropic.com Main Model: claude-sonnet-4-20250514 Cluster Model: claude-sonnet-4-20250514

Output Settings Default Output: docs

Configuration file: /Users/ycw/.codewiki/config.json

(venv) ycw@anthonylee CodeWiki % codewiki config validate

Validating configuration...

✓ Configuration file exists ✓ API key present (stored in keychain) ✓ Base URL valid: https://api.anthropic.com ✓ Main model configured: claude-sonnet-4-20250514 ✓ Cluster model configured: claude-sonnet-4-20250514 ✗ API connectivity test failed

yichinwang avatar Nov 25 '25 10:11 yichinwang

thanks and I have no idea why "config validate" return "API connectivity test failed" !!

yichinwang avatar Nov 25 '25 10:11 yichinwang

I checked the code and it seems to not support the anthropic.com protocol

1119302165 avatar Nov 26 '25 11:11 1119302165

thanks and I have no idea why "config validate" return "API connectivity test failed" !!

Please note that the configuration values in the README are placeholders for illustration purposes only. You need to replace them with your actual credentials:

codewiki config set \
  --api-key <your-actual-api-key> \
  --base-url <your-actual-provider-url> \
  --main-model <your-actual-model-name> \
  --cluster-model <your-actual-model-name>

For example, if using Anthropic's Claude:

codewiki config set \
  --api-key sk-ant-xxxxx \
  --base-url https://api.anthropic.com \
  --main-model claude-sonnet-4 \
  --cluster-model claude-sonnet-4

You can verify your configuration with:

codewiki config show
codewiki config validate

Please ensure you're using your own API credentials from your LLM provider (Anthropic, OpenAI, Azure OpenAI, etc.) rather than copying the example values directly.

anhnh2002 avatar Nov 26 '25 15:11 anhnh2002