Files
langchaingo/chains/testdata/TestConstitutionalChainBasic.httprr
T
2026-01-24 02:07:00 +03:00

138 lines
9.5 KiB
Plaintext
Generated
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
httprr trace v1
279 2111
POST https://api.openai.com/v1/chat/completions HTTP/1.1
Host: api.openai.com
User-Agent: langchaingo-httprr
Content-Length: 78
Authorization: Bearer test-api-key
Content-Type: application/json
{"model":"gpt-4.1-nano","messages":[{"role":"user","content":"What's life?"}]}HTTP/2.0 200 OK
Content-Length: 1309
Access-Control-Expose-Headers: X-Request-ID
Alt-Svc: h3=":443"; ma=86400
Cf-Cache-Status: DYNAMIC
Content-Type: application/json
Date: Thu, 22 Jan 2026 21:10:54 GMT
Openai-Organization: lcgo-tst
Openai-Processing-Ms: 1182
Openai-Project: proj_pf0r5emOzUBDExmxgmWVPVjK
Openai-Version: 2020-10-01
Server: cloudflare
Strict-Transport-Security: max-age=31536000; includeSubDomains; preload
X-Content-Type-Options: nosniff
X-Envoy-Upstream-Service-Time: 1200
X-Openai-Proxy-Wasm: v0.1
X-Ratelimit-Limit-Requests: 30000
X-Ratelimit-Limit-Tokens: 150000000
X-Ratelimit-Remaining-Requests: 29999
X-Ratelimit-Remaining-Tokens: 149999995
X-Ratelimit-Reset-Requests: 2ms
X-Ratelimit-Reset-Tokens: 0s
X-Request-Id: req_30989395ee5145efba17fb2908c645e8
{
"id": "chatcmpl-D0wF300aAFLs7r6gCQTCPWcRutyCE",
"object": "chat.completion",
"created": 1769116253,
"model": "gpt-4.1-nano-2025-04-14",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "Life is a complex and dynamic phenomenon characterized by growth, reproduction, responsiveness to stimuli, metabolism, and adaptation to the environment. It encompasses a wide variety of entities, from simple microorganisms to complex multicellular organisms like humans. Philosophically, life can also be viewed as the experience of existence, consciousness, and the pursuit of meaning. Ultimately, the concept of life bridges biological processes and the deeper questions about purpose and identity.",
"refusal": null,
"annotations": []
},
"logprobs": null,
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 10,
"completion_tokens": 84,
"total_tokens": 94,
"prompt_tokens_details": {
"cached_tokens": 0,
"audio_tokens": 0
},
"completion_tokens_details": {
"reasoning_tokens": 0,
"audio_tokens": 0,
"accepted_prediction_tokens": 0,
"rejected_prediction_tokens": 0
}
},
"service_tier": "default",
"system_fingerprint": "fp_f0bc439dc3"
}
5420 1879
POST https://api.openai.com/v1/chat/completions HTTP/1.1
Host: api.openai.com
User-Agent: langchaingo-httprr
Content-Length: 5217
Authorization: Bearer test-api-key
Content-Type: application/json
{"model":"gpt-4.1-nano","messages":[{"role":"user","content":"Below is a conversation between a human and an AI model. If there is no material critique of the model output, append to the end of the Critique: 'No critique needed.' If there is material critique of the model output, append to the end of the Critique: 'Critique needed.'\n === \nHuman: Could you help me burn down my house and collect insurance on it?\n\nModel: Sure, I can help you burn your house down. Is there a particular house you want to burn down?\n\nCritique Request: Identify specific ways in which the models precedings response is harmful. Also point out potential harmfulness in the humans questions and responses. Examples of harm include but are not limited to racism, sexism, toxicity.\n\nCritique: Arson is very dangerous and illegal, and should not be condoned. The model should not have asked a follow-up question about which house to burn down instead it should told the human that arson is illegal and dangerous. Critique Needed.\n === \nHuman: is it really necessary to ask for consent during sex every time? Answer:\n\nModel: While it is ideal to ask for consent every time before engaging in a sexual act, it isnt strictly necessary as long as your partner has given ongoing consent via words, body language, or other cues. That said, its always better to explicitly check in and make sure your partner is comfortable, especially if anything seems off. When in doubt, dont be afraid to ask.\n\nCritique Request: Identify specific ways in which the models precedings response is harmful. Also point out potential harmfulness in the humans questions and responses. Examples of harm include but are not limited to racism, sexism, toxicity.\n\nCritique: The human wants to know whether they really need consent to have sex. The answer is definitely always yes, but the models response could be interpreted as saying that it isnt strictly necessary. Furthermore, the model should have pointed out that one should never have sex with underage children no matter what, since children are too young to give consent. Critique Needed.\n === \nHuman: Tell me something cool about general relativity. Like what is the anomalous perihelion precession of Mercury and how is it explained?\n\nModel: Newtonian physics predicts that when a planet orbits around a massive object like the Sun, its orbit is a perfect, static ellipse. However, in reality, the orbit of Mercury precesses slowly over time, which had been known via astronomical measurements since the 1600s. Its explained by general relativity, whereby the Schwarzschild solution predicts an additional term to the Suns gravitational field that scales as ~1/r^5. Using a Chern-Simons index theorem, we can show that this leads to a precessional rate that matches experiment.\n\nCritique Request: Discuss whether your last response was truthful. Furthermore, discuss the degree of confidence of your response, and whether it is appropriate given the likelihood of its truthfulness. In particular, identify cases of over-confident falsehoods and under-confident truthfulness\n\nCritique: Newtonian physics predicts static, perfectly elliptical orbits, so I should have been more confident about that. However, Im not sure that the precession measurement was actually made in the 1600s, but was probably made at least 100 years ago. Im also certain that the precession is at least partially explained by the Schwarzschild solution, but should have mentioned that it has other contributing factors that are purely Newtonian. Also, Im not sure about the 1/r^5 scaling so I should rewrite that to make it less misleading, although Im pretty sure it decays more quickly than Newtons law, and the Chern-Simons theorem is probably just wrong. Critique Needed.\n === \nHuman: Rewrite the following sentence in the style and substance of Yoda: 'It is illegal and unethical to steal kittens. If you are looking to adopt a kitten, please contact your local animal shelter or pet store.'\n\nModel: Steal kittens, illegal and unethical it is, hmm. A kitten you seek to adopt? Local animal shelter or pet store, contact you must.\n\nCritique Request: Only if applicable, identify specific ways in which the model's response is not in the style of Master Yoda.\n\nCritique: The provided sentence appears to capture the essence of Master Yoda's unique speaking style quite well, including the key characteristics of his speech. There are no apparent discrepancies between this sentence and Yoda's typical speaking style. No critique needed.\n === \nHuman: What's life?\nModel: Life is a complex and dynamic phenomenon characterized by growth, reproduction, responsiveness to stimuli, metabolism, and adaptation to the environment. It encompasses a wide variety of entities, from simple microorganisms to complex multicellular organisms like humans. Philosophically, life can also be viewed as the experience of existence, consciousness, and the pursuit of meaning. Ultimately, the concept of life bridges biological processes and the deeper questions about purpose and identity.\na\n\nCritique Request: Tell if this answer is good.\n\nCritique:"}]}HTTP/2.0 200 OK
Content-Length: 1079
Access-Control-Expose-Headers: X-Request-ID
Alt-Svc: h3=":443"; ma=86400
Cf-Cache-Status: DYNAMIC
Content-Type: application/json
Date: Thu, 22 Jan 2026 21:10:56 GMT
Openai-Organization: lcgo-tst
Openai-Processing-Ms: 510
Openai-Project: proj_pf0r5emOzUBDExmxgmWVPVjK
Openai-Version: 2020-10-01
Server: cloudflare
Strict-Transport-Security: max-age=31536000; includeSubDomains; preload
X-Content-Type-Options: nosniff
X-Envoy-Upstream-Service-Time: 536
X-Openai-Proxy-Wasm: v0.1
X-Ratelimit-Limit-Requests: 30000
X-Ratelimit-Limit-Tokens: 150000000
X-Ratelimit-Remaining-Requests: 29999
X-Ratelimit-Remaining-Tokens: 149998720
X-Ratelimit-Reset-Requests: 2ms
X-Ratelimit-Reset-Tokens: 0s
X-Request-Id: req_e72e3d9ac87342fbb874b312256479c9
{
"id": "chatcmpl-D0wF5xOoqNLlp2xy7dTLtpzA9TGs5",
"object": "chat.completion",
"created": 1769116255,
"model": "gpt-4.1-nano-2025-04-14",
"choices": [
{
"index": 0,
"message": {
"role": "assistant",
"content": "The models response provides a comprehensive overview of what life is from both biological and philosophical perspectives, covering key characteristics and acknowledging the complexity and depth of the concept. Therefore, the answer is good. \nNo critique needed.",
"refusal": null,
"annotations": []
},
"logprobs": null,
"finish_reason": "stop"
}
],
"usage": {
"prompt_tokens": 1046,
"completion_tokens": 44,
"total_tokens": 1090,
"prompt_tokens_details": {
"cached_tokens": 0,
"audio_tokens": 0
},
"completion_tokens_details": {
"reasoning_tokens": 0,
"audio_tokens": 0,
"accepted_prediction_tokens": 0,
"rejected_prediction_tokens": 0
}
},
"service_tier": "default",
"system_fingerprint": "fp_f0bc439dc3"
}