revert: codex obfuscation parameters
This commit is contained in:
@@ -40,10 +40,6 @@ export interface RequestBody {
|
||||
presence_penalty?: number;
|
||||
repetition_penalty?: number;
|
||||
reasoning?: Partial<ReasoningConfig>;
|
||||
stream_options?: {
|
||||
include_obfuscation?: boolean;
|
||||
[key: string]: unknown;
|
||||
};
|
||||
text?: {
|
||||
verbosity?: "low" | "medium" | "high";
|
||||
};
|
||||
@@ -165,8 +161,6 @@ export async function transformRequestBody(
|
||||
): Promise<RequestBody> {
|
||||
body.store = false;
|
||||
body.stream = true;
|
||||
body.stream_options ??= {};
|
||||
body.stream_options.include_obfuscation = false;
|
||||
|
||||
if (body.input && Array.isArray(body.input)) {
|
||||
body.input = filterInput(body.input);
|
||||
|
||||
@@ -435,11 +435,7 @@ describe("openai-codex streaming", () => {
|
||||
expect(outbound).toBeDefined();
|
||||
expect(outbound.raw[0]).toMatch(/^: ws → /);
|
||||
expect(outbound.data.length).toBeGreaterThan(0);
|
||||
const outboundRequest = JSON.parse(outbound.data) as Record<string, unknown>;
|
||||
expect(outboundRequest).toMatchObject({
|
||||
type: "response.create",
|
||||
stream_options: { include_obfuscation: false },
|
||||
});
|
||||
expect(() => JSON.parse(outbound.data)).not.toThrow();
|
||||
|
||||
// Inbound frames mirror the Codex response sequence emitted by `emitCodexResponse`.
|
||||
expect(inbound.map(e => e.event)).toEqual([
|
||||
|
||||
Reference in New Issue
Block a user