SciSharp / SciSharp/BotSharp

Add a regex expression validation for required fields.

Open
#185 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
3.1k
Forks
651
Avg merge
15h 2m
Merged PRs (30d)
36

Description

Sometimes LLM will hallucinate and simulate a value that does not exist. For example, it fills in a false value in the order number below. I want a user-defined validator that can validate the data format in advance.

{ "function": "route_to_agent",
  "reason": "User wants to pay in cash",
  "next_action_agent": "Payment",
  "user_goal_agent": "Payment",
  "args": {
    "order_number": "order number"
  }
}

Below is part of the Router prompt:

* Agent: Payment
Make payment when user wants to pay for the order
Required args: {
    "order_number": "order number",
    }

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing how the Router handles required args and agent prompts. Determine where a user-defined regex validator would fit, then verify that a fabricated order_number such as "order number" is rejected while a matching value is accepted.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
ai
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.