mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-10-03 05:59:43 +02:00
- Remove unused validateTokenCounts/validateTokensAndCost exports and PlanPhase type alias - Add execPattern() helper to eliminate 8 repetitive .lastIndex=0 + exec() loops - Centralize 11 magic number constants into config/ai-defaults.ts and config/server-timing.ts - Remove stale src/tui from tsconfig.json exclude - Fix CLAUDE.md inaccuracies (session helpers, app.js line count, module count) - Add 316 new tests: LRUMap (38), StaleExpirationMap (42), BufferAccumulator (33), respawn helpers (142), system-routes expansion (11→61) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
14 lines
339 B
TypeScript
14 lines
339 B
TypeScript
/**
|
|
* @fileoverview Token validation constants.
|
|
*
|
|
* Claude's context window is ~200k tokens, so 500k is a generous upper bound.
|
|
*
|
|
* @module utils/token-validation
|
|
*/
|
|
|
|
/**
|
|
* Maximum tokens allowed per session.
|
|
* Claude's context is ~200k, so 500k is a safe upper bound for validation.
|
|
*/
|
|
export const MAX_SESSION_TOKENS = 500_000;
|