Skip to content
This repository was archived by the owner on Dec 11, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions notdiamond/llms/providers.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ class NDLLMProviders(Enum):
GPT_4_1_MINI_2025_04_14 (NDLLMProvider): refers to 'gpt-4.1-mini-2025-04-14' model by OpenAI
GPT_4_1_NANO (NDLLMProvider): refers to 'gpt-4.1-nano' model by OpenAI
GPT_4_1_NANO_2025_04_14 (NDLLMProvider): refers to 'gpt-4.1-nano-2025-04-14' model by OpenAI
GPT_4o_2024_11_20 (NDLLMProvider): refers to 'gpt-4o-2024-11-20' model by OpenAI

CLAUDE_2_1 (NDLLMProvider): refers to 'claude-2.1' model by Anthropic
CLAUDE_3_OPUS_20240229 (NDLLMProvider): refers to 'claude-3-opus-20240229' model by Anthropic
Expand Down Expand Up @@ -114,6 +115,7 @@ class NDLLMProviders(Enum):
GPT_4_1_NANO = ("openai", "gpt-4.1-nano")
GPT_4_1_NANO_2025_04_14 = ("openai", "gpt-4.1-nano-2025-04-14")
CHATGPT_4o_LATEST = ("openai", "chatgpt-4o-latest")
GPT_4o_2024_11_20 = ("openai", "gpt-4o-2024-11-20")

CLAUDE_2_1 = ("anthropic", "claude-2.1")
CLAUDE_3_OPUS_20240229 = ("anthropic", "claude-3-opus-20240229")
Expand Down
5 changes: 5 additions & 0 deletions notdiamond/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
"gpt-4o",
"gpt-4o-2024-05-13",
"gpt-4o-2024-08-06",
"gpt-4o-2024-11-20",
"gpt-4o-mini",
"gpt-4o-mini-2024-07-18",
"gpt-4-turbo-preview",
Expand All @@ -58,6 +59,7 @@
"gpt-4o",
"gpt-4o-2024-05-13",
"gpt-4o-2024-08-06",
"gpt-4o-2024-11-20",
"gpt-4o-mini",
"gpt-4o-mini-2024-07-18",
"gpt-4-turbo-preview",
Expand All @@ -80,6 +82,7 @@
"gpt-4o",
"gpt-4o-2024-05-13",
"gpt-4o-2024-08-06",
"gpt-4o-2024-11-20",
"gpt-4o-mini",
"gpt-4o-mini-2024-07-18",
"gpt-4-turbo-preview",
Expand All @@ -100,6 +103,7 @@
"gpt-4o": "openai/gpt-4o",
"gpt-4o-2024-05-13": "openai/gpt-4o-2024-05-13",
"gpt-4o-2024-08-06": "openai/gpt-4o-2024-08-06",
"gpt-4o-2024-11-20": "openai/gpt-4o-2024-11-20",
"gpt-4o-mini": "openai/gpt-4o-mini",
"gpt-4o-mini-2024-07-18": "openai/gpt-4o-mini-2024-07-18",
"gpt-4-turbo-preview": "openai/gpt-4-turbo-preview",
Expand All @@ -122,6 +126,7 @@
"gpt-4o": {"input": 5.0, "output": 15.0},
"gpt-4o-2024-05-13": {"input": 5.0, "output": 15.0},
"gpt-4o-2024-08-06": {"input": 2.5, "output": 10.0},
"gpt-4o-2024-11-20": {"input": 2.5, "output": 10.0},
"gpt-4o-mini": {"input": 0.15, "output": 0.6},
"gpt-4o-mini-2024-07-18": {"input": 0.15, "output": 0.6},
"gpt-4-turbo-preview": {"input": 10.0, "output": 30.0},
Expand Down

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,177 @@
interactions:
- request:
body: '{"messages": [{"role": "user", "content": "Tell me a joke"}], "llm_providers":
[{"provider": "openai", "model": "gpt-4o-2024-11-20", "is_custom": false, "context_length":
null, "input_price": null, "output_price": null, "latency": null}], "metric":
"accuracy", "max_model_depth": 1, "hash_content": true}'
headers:
Accept:
- '*/*'
Accept-Encoding:
- gzip, deflate, zstd
Connection:
- keep-alive
Content-Length:
- '304'
User-Agent:
- Python-SDK/0.4.5
content-type:
- application/json
method: POST
uri: https://staging-api.notdiamond.ai/v2/modelRouter/modelSelect
response:
body:
string: '{"providers":[{"provider":"openai","model":"gpt-4o-2024-11-20"}],"session_id":"b71e9207-67a1-4004-bc22-88e1fcf60397"}'
headers:
CF-RAY:
- 981a666b894eeee5-OTP
Connection:
- keep-alive
Content-Type:
- application/json
Date:
- Fri, 19 Sep 2025 16:18:39 GMT
Server:
- cloudflare
Transfer-Encoding:
- chunked
alt-svc:
- h3=":443"; ma=86400
cf-cache-status:
- DYNAMIC
content-length:
- '117'
rndr-id:
- bd78ff32-4a04-48be
vary:
- Accept-Encoding
x-render-origin-server:
- uvicorn
x-request-id:
- bd78ff32-4a04-48be
status:
code: 200
message: OK
- request:
body: '{"messages":[{"content":"The output should be formatted as a JSON instance
that conforms to the JSON schema below.\n\nAs an example, for the schema {\"properties\":
{\"foo\": {\"title\": \"Foo\", \"description\": \"a list of strings\", \"type\":
\"array\", \"items\": {\"type\": \"string\"}}}, \"required\": [\"foo\"]}\nthe
object {\"foo\": [\"bar\", \"baz\"]} is a well-formatted instance of the schema.
The object {\"properties\": {\"foo\": [\"bar\", \"baz\"]}} is not well-formatted.\n\nHere
is the output schema:\n```\n{\"properties\": {\"setup\": {\"description\": \"question
to set up a joke\", \"title\": \"Setup\", \"type\": \"string\"}, \"punchline\":
{\"description\": \"answer to resolve the joke\", \"title\": \"Punchline\",
\"type\": \"string\"}}, \"required\": [\"setup\", \"punchline\"]}\n```\nTell
me a joke","role":"user"}],"model":"gpt-4o-2024-11-20","max_completion_tokens":200,"stream":false}'
headers:
accept:
- application/json
accept-encoding:
- gzip, deflate, zstd
connection:
- keep-alive
content-length:
- '912'
content-type:
- application/json
host:
- api.openai.com
user-agent:
- OpenAI/Python 1.99.9
x-stainless-arch:
- arm64
x-stainless-async:
- 'false'
x-stainless-lang:
- python
x-stainless-os:
- MacOS
x-stainless-package-version:
- 1.99.9
x-stainless-read-timeout:
- '120.0'
x-stainless-retry-count:
- '0'
x-stainless-runtime:
- CPython
x-stainless-runtime-version:
- 3.11.12
method: POST
uri: https://api.openai.com/v1/chat/completions
response:
body:
string: "{\n \"id\": \"chatcmpl-CHY6hWOi2w6AHzBTxm4UGGyzMVf3p\",\n \"object\":
\"chat.completion\",\n \"created\": 1758298719,\n \"model\": \"gpt-4o-2024-11-20\",\n
\ \"choices\": [\n {\n \"index\": 0,\n \"message\": {\n \"role\":
\"assistant\",\n \"content\": \"```json\\n{\\n \\\"setup\\\": \\\"Why
don't skeletons fight each other?\\\",\\n \\\"punchline\\\": \\\"Because
they don't have the guts!\\\"\\n}\\n```\",\n \"refusal\": null,\n \"annotations\":
[]\n },\n \"logprobs\": null,\n \"finish_reason\": \"stop\"\n
\ }\n ],\n \"usage\": {\n \"prompt_tokens\": 200,\n \"completion_tokens\":
33,\n \"total_tokens\": 233,\n \"prompt_tokens_details\": {\n \"cached_tokens\":
0,\n \"audio_tokens\": 0\n },\n \"completion_tokens_details\":
{\n \"reasoning_tokens\": 0,\n \"audio_tokens\": 0,\n \"accepted_prediction_tokens\":
0,\n \"rejected_prediction_tokens\": 0\n }\n },\n \"service_tier\":
\"default\",\n \"system_fingerprint\": \"fp_561b2577db\"\n}\n"
headers:
CF-RAY:
- 981a66745b9b6af8-OTP
Connection:
- keep-alive
Content-Type:
- application/json
Date:
- Fri, 19 Sep 2025 16:18:40 GMT
Server:
- cloudflare
Set-Cookie:
- __cf_bm=uYfxgdqoC180lMNZXNjLPS_3gi.EHo.a2JasETW3bAM-1758298720-1.0.1.1-QRlP.iA1ApN65HevWF7_VcZz9vuhpjozkxXcPmfUoxc53PoTnXFxSxLbBoQwMhT3QQh5O9TzHWsXwFNKbQ5UzmuawYcZVYDl1yRuHAtAGBY;
path=/; expires=Fri, 19-Sep-25 16:48:40 GMT; domain=.api.openai.com; HttpOnly;
Secure; SameSite=None
- _cfuvid=SsSyRRrlMGl7SKR2IHxeWJF0H.tVYnSLMH173nmDCFY-1758298720035-0.0.1.1-604800000;
path=/; domain=.api.openai.com; HttpOnly; Secure; SameSite=None
Strict-Transport-Security:
- max-age=31536000; includeSubDomains; preload
Transfer-Encoding:
- chunked
X-Content-Type-Options:
- nosniff
access-control-expose-headers:
- X-Request-ID
alt-svc:
- h3=":443"; ma=86400
cf-cache-status:
- DYNAMIC
content-length:
- '935'
openai-organization:
- not-diamond-bdz8cg
openai-processing-ms:
- '457'
openai-project:
- proj_EvMLZJqcggqzjvd3BFXe4tfP
openai-version:
- '2020-10-01'
x-envoy-upstream-service-time:
- '470'
x-openai-proxy-wasm:
- v0.1
x-ratelimit-limit-requests:
- '10000'
x-ratelimit-limit-tokens:
- '30000000'
x-ratelimit-remaining-requests:
- '9999'
x-ratelimit-remaining-tokens:
- '29999818'
x-ratelimit-reset-requests:
- 6ms
x-ratelimit-reset-tokens:
- 0s
x-request-id:
- req_b13629042809448e98ded097d4702e5d
status:
code: 200
message: OK
version: 1
Loading
Loading