Skip to content

feat: metadata#27

Merged
drorIvry merged 1 commit into
mainfrom
feature/user-metadata-FIRE-1096
Jan 30, 2026
Merged

feat: metadata#27
drorIvry merged 1 commit into
mainfrom
feature/user-metadata-FIRE-1096

Conversation

@drorIvry

@drorIvry drorIvry commented Jan 29, 2026

Copy link
Copy Markdown
Collaborator

Description of change

Pull-Request Checklist

  • Code is up-to-date with the main branch
  • npm run lint passes with this change
  • npm run test passes with this change
  • This pull request links relevant issues as Fixes #0000
  • There are new or updated unit tests validating the change
  • Documentation has been updated to reflect this change
  • The new commits follow conventions outlined in the conventional commit spec

Summary by CodeRabbit

  • New Features

    • Added optional metadata support to evaluation requests for custom key-value tracking and contextual information.
    • Added optional allowed topics field to evaluation requests for topic-based filtering.
  • Chores

    • Version bumped to 1.6.0.

✏️ Tip: You can customize this high-level summary in your review settings.

@drorIvry drorIvry requested a review from yuval-qf January 29, 2026 21:12
@coderabbitai

coderabbitai Bot commented Jan 29, 2026

Copy link
Copy Markdown

Walkthrough

This PR bumps the package version to 1.6.0 and adds metadata propagation and optional topic filtering to the evaluation system. Two new optional fields—metadata (Record<string, string>) and allowedTopics (string[])—are introduced across evaluation request types and propagated through both backward-compatible and converter-based evaluation paths.

Changes

Cohort / File(s) Summary
Version Bump
package.json
Updated package version from 1.5.1 to 1.6.0.
Metadata & Topic Filtering
src/index.ts, src/types.ts
Added optional metadata and allowedTopics fields to evaluation request types (EvaluationRequestV2, EvaluationProxyAPIRequest). Extended invokeEvaluation method to accept and forward metadata in request body. Updated Zod schemas to validate new optional fields.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Poem

🐰 Metadata hops and topics dance,
Evaluation blooms with second chance,
Allow topics through, keep secrets near,
Version six point oh brings cheer! ✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Title check ❓ Inconclusive The title 'feat: metadata' is vague and overly generic, failing to meaningfully describe what metadata functionality was added or which components were modified. Enhance the title to be more specific and descriptive, such as 'feat: add metadata support to evaluation requests' to clearly indicate the scope and purpose of the changes.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feature/user-metadata-FIRE-1096

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 0

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/index.ts (1)

269-279: Backward-compat path doesn’t forward allowedTopics.

EvaluationProxyAPIRequestSchema now supports allowedTopics, but the backward-compat payload omits it, so the feature won’t work for direct-message callers. Add the mapped field to the request body.

✅ Suggested fix
       topic_scoping_target:
         evaluationProxyAPIRequest.topicScopingTarget ??
         evaluationProxyAPIRequest.topic_scoping_target,
+      allowed_topics: evaluationProxyAPIRequest.allowedTopics,
       metadata: evaluationProxyAPIRequest.metadata,

@yuval-qf yuval-qf left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

@drorIvry drorIvry merged commit fee6f10 into main Jan 30, 2026
3 checks passed
@drorIvry drorIvry deleted the feature/user-metadata-FIRE-1096 branch January 30, 2026 08:28
@coderabbitai coderabbitai Bot mentioned this pull request Feb 1, 2026
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants