Skip to content

Conversation

tcdent
Copy link
Collaborator

@tcdent tcdent commented Jun 18, 2025

Summary

  • fix attribute mapping for response spans
  • remove stale JS build artifacts
  • update unit tests for new Client-based constructor

Testing

  • npm test

https://chatgpt.com/codex/tasks/task_e_6852e5949fcc832fbe0bbbb0d339a09e


if (Array.isArray(data._input)) {
data._input.forEach((item, i) => {
if (item.type === 'message') {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I liked this as a case statement for extensibility.

debug('Skipping function call result');
break;
default:
debug('Unknown input item type:', item.type);
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should also retain the debug message for unhandled types so we know to instrument them in the future.

default:
debug('Unknown message content type:', contentItem.type);
break;
if (item.type === 'message') {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, I prefer the case statements.

extractAttributesFromMapping(item, RESPONSE_TOOL_CALL_ATTRIBUTES));
break;
}
case 'image_generation_call': // ResponseOutputItem.ImageGenerationCall
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maintain these cases and the comments for future development.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant