• Your Name's avatar
    fix: use actual token usage from Kiro API instead of hardcoded 0 · 17870cbf
    Your Name authored
    - Added usage tracking to AwsEventStreamParser
    - Parser now stores usage_credits and context_usage_percentage
    - Added get_usage() method to retrieve usage data
    - Updated handler to pass usage data to response builder
    - Non-streaming: Uses actual usage_credits as total_tokens
    - Streaming: Includes usage_credits in final chunk
    - Falls back to 0 if Kiro API doesn't provide usage data
    - Prevents over-estimation when Kiro returns 0 tokens
    17870cbf
Name
Last commit
Last update
aisbf Loading commit data...
config Loading commit data...
docs/superpowers Loading commit data...
static Loading commit data...
templates Loading commit data...
tests/payments Loading commit data...
.gitignore Loading commit data...
.providers.json.swp Loading commit data...
ADMIN_SETTINGS_CLARIFICATION.md Loading commit data...
ADMIN_SETTINGS_COMPLETE.md Loading commit data...
AI.PROMPT Loading commit data...
ANALYTICS_FIX.md Loading commit data...
API_EXAMPLES.md Loading commit data...
BUILD_DEPLOY.md Loading commit data...
CHANGELOG.md Loading commit data...
COMPLETE_SUMMARY.md Loading commit data...
CRITICAL_FIX_TEMPLATE.md Loading commit data...
DATABASE_MIGRATION.md Loading commit data...
DEBUG_GUIDE.md Loading commit data...
DEPLOYMENT_CHECKLIST.md Loading commit data...
DEPLOYMENT_READY.md Loading commit data...
DOCUMENTATION.md Loading commit data...
FINAL_REPORT.md Loading commit data...
FINAL_SESSION_SUMMARY.md Loading commit data...
FINAL_STATUS.md Loading commit data...
FINAL_SUMMARY_v0.99.26.txt Loading commit data...
KILO_OAUTH2.md Loading commit data...
LICENSE.txt Loading commit data...
MANIFEST.in Loading commit data...
MIGRATION_FIXES.md Loading commit data...
MYSQL_MIGRATION_FIX.md Loading commit data...
PAYMENT_GATEWAY_ISSUE_ANALYSIS.md Loading commit data...
PAYMENT_INSTALLATION.md Loading commit data...
PAYMENT_INTEGRATION_SUMMARY.md Loading commit data...
PAYMENT_SETTINGS_MIGRATION.md Loading commit data...
PAYMENT_SYSTEM_SUMMARY.md Loading commit data...
PAYPAL_SETUP.md Loading commit data...
PAYPAL_TROUBLESHOOTING.md Loading commit data...
PYPI.md Loading commit data...
QUICK_START_PAYMENT.md Loading commit data...
README.md Loading commit data...
REFACTORING_SUMMARY.md Loading commit data...
RELEASE_NOTES_v0.99.26.md Loading commit data...
SESSION_SUMMARY.md Loading commit data...
TODO.md Loading commit data...
TORRC_SETUP.md Loading commit data...
aisbf.db Loading commit data...
aisbf.sh Loading commit data...
build.sh Loading commit data...
chatgpt-api-implementation-guide.md Loading commit data...
clean.sh Loading commit data...
cli.py Loading commit data...
codex-oauth-implementation-guide.md Loading commit data...
diagnose_databases.py Loading commit data...
main.py Loading commit data...
migrate_cache_to_aisbf.py Loading commit data...
pyproject.toml Loading commit data...
qwen-oauth2-analysis.md Loading commit data...
requirements.txt Loading commit data...
screenshot.png Loading commit data...
setup.py Loading commit data...
start_proxy.sh Loading commit data...
test_google.sh Loading commit data...
test_kiro_models_origin.py Loading commit data...
test_proxy.sh Loading commit data...
test_response_cache.py Loading commit data...
verify_release.sh Loading commit data...