| 201 | } |
| 202 | |
| 203 | nlohmann::json TestDataGenerator::createFullValidResponse() { |
| 204 | return nlohmann::json{ |
| 205 | {"id", "chatcmpl-full123"}, |
| 206 | {"object", "chat.completion"}, |
| 207 | {"created", 1234567890}, |
| 208 | {"model", "gpt-4o"}, |
| 209 | {"system_fingerprint", "fp_full123"}, |
| 210 | {"choices", |
| 211 | nlohmann::json::array( |
| 212 | {{{"index", 0}, |
| 213 | {"message", |
| 214 | {{"role", "assistant"}, |
| 215 | {"content", "This is a complete response with all fields."}}}, |
| 216 | {"finish_reason", "stop"}, |
| 217 | {"logprobs", nullptr}}})}, |
| 218 | {"usage", |
| 219 | {{"prompt_tokens", 25}, |
| 220 | {"completion_tokens", 45}, |
| 221 | {"total_tokens", 70}}}}; |
| 222 | } |
| 223 | |
| 224 | nlohmann::json TestDataGenerator::createResponseWithUsage( |
| 225 | int prompt_tokens, |
nothing calls this directly
no outgoing calls
no test coverage detected