|
1139 | 1139 | } |
1140 | 1140 | }, |
1141 | 1141 | { |
1142 | | - "reason": "Tracks LLM usage costs across operations.", |
1143 | | - "description": "Records token usage and calculates costs. Aggregates costs across workflow steps.", |
1144 | | - "dependencies": [], |
| 1142 | + "reason": "Click decorator that tracks per-command LLM cost, model, and attempted-models history to a CSV file.", |
| 1143 | + "description": "Records token usage and calculates costs. Aggregates costs across workflow steps. Captures chronological attempted-models history (including failed cloud attempts that fell back to local) via ctx.obj['attempted_models'].", |
| 1144 | + "dependencies": [ |
| 1145 | + "llm_invoke_python.prompt" |
| 1146 | + ], |
1145 | 1147 | "priority": 33, |
1146 | 1148 | "filename": "track_cost_python.prompt", |
1147 | 1149 | "filepath": "pdd/track_cost.py", |
|
1156 | 1158 | { |
1157 | 1159 | "name": "track_cost", |
1158 | 1160 | "signature": "(func)", |
1159 | | - "returns": "None", |
| 1161 | + "returns": "Callable", |
1160 | 1162 | "sideEffects": [ |
1161 | 1163 | "None" |
1162 | 1164 | ] |
|
1171 | 1173 | }, |
1172 | 1174 | { |
1173 | 1175 | "name": "collect_files", |
1174 | | - "signature": "(args, kwargs)", |
1175 | | - "returns": "None", |
1176 | | - "sideEffects": [ |
1177 | | - "None" |
1178 | | - ] |
1179 | | - }, |
1180 | | - { |
1181 | | - "name": "wrapper", |
1182 | | - "signature": "()", |
1183 | | - "returns": "None", |
| 1176 | + "signature": "(args, kwargs) -> Tuple[List[str], List[str]]", |
| 1177 | + "returns": "Tuple[List[str], List[str]]", |
1184 | 1178 | "sideEffects": [ |
1185 | 1179 | "None" |
1186 | 1180 | ] |
1187 | 1181 | }, |
1188 | 1182 | { |
1189 | 1183 | "name": "looks_like_file", |
1190 | | - "signature": "(path_str)", |
1191 | | - "returns": "None", |
| 1184 | + "signature": "(path_str) -> bool", |
| 1185 | + "returns": "bool", |
1192 | 1186 | "sideEffects": [ |
1193 | 1187 | "None" |
1194 | 1188 | ] |
|
8984 | 8978 | ] |
8985 | 8979 | } |
8986 | 8980 | } |
| 8981 | + }, |
| 8982 | + { |
| 8983 | + "reason": "Provides unified LLM invocation across all PDD operations with provider abstraction, retries, and context window validation.", |
| 8984 | + "description": "Provides unified LLM invocation across all PDD operations with provider abstraction, retries, and context window validation.", |
| 8985 | + "dependencies": [ |
| 8986 | + "path_resolution_python.prompt", |
| 8987 | + "server/token_counter_python.prompt" |
| 8988 | + ], |
| 8989 | + "priority": 236, |
| 8990 | + "filename": "llm_invoke_python.prompt", |
| 8991 | + "filepath": "pdd/llm_invoke.py", |
| 8992 | + "tags": [ |
| 8993 | + "module", |
| 8994 | + "python" |
| 8995 | + ], |
| 8996 | + "interface": { |
| 8997 | + "type": "module", |
| 8998 | + "module": { |
| 8999 | + "functions": [ |
| 9000 | + { |
| 9001 | + "name": "llm_invoke", |
| 9002 | + "signature": "(prompt, input_json, strength, temperature, verbose, output_pydantic, output_schema, time, use_batch_mode, messages, language, use_cloud)", |
| 9003 | + "returns": "Dict[str, Any]" |
| 9004 | + }, |
| 9005 | + { |
| 9006 | + "name": "setup_file_logging", |
| 9007 | + "signature": "(log_file_path=None)", |
| 9008 | + "returns": "None" |
| 9009 | + }, |
| 9010 | + { |
| 9011 | + "name": "set_verbose_logging", |
| 9012 | + "signature": "(verbose=False)", |
| 9013 | + "returns": "None" |
| 9014 | + }, |
| 9015 | + { |
| 9016 | + "name": "set_quiet_logging", |
| 9017 | + "signature": "()", |
| 9018 | + "returns": "None" |
| 9019 | + } |
| 9020 | + ] |
| 9021 | + } |
| 9022 | + } |
8987 | 9023 | } |
8988 | 9024 | ] |
0 commit comments