Skip to content

Commit

Permalink
Update checkbox IDs and labels
Browse files Browse the repository at this point in the history
  • Loading branch information
miurla committed Apr 7, 2024
1 parent c116df1 commit 261325e
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 8 deletions.
6 changes: 3 additions & 3 deletions components/copilot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -133,15 +133,15 @@ export const Copilot: React.FC<CopilotProps> = ({
className="flex items-center space-x-1.5 mb-2"
>
<Checkbox
id={option?.name}
name={option?.name}
id={option?.value}
name={option?.value}
onCheckedChange={() =>
handleOptionChange(option?.label as string)
}
/>
<label
className="text-sm whitespace-nowrap pr-4"
htmlFor={option?.name}
htmlFor={option?.value}
>
{option?.label}
</label>
Expand Down
2 changes: 1 addition & 1 deletion components/header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ export const Header: React.FC = () => {
<div className="p-2">
<a href="/">
<IconLogo className={cn('w-5 h-5')} />
<span className="sr-only">Metamorphic</span>
<span className="sr-only">Morphic</span>
</a>
</div>
<ModeToggle />
Expand Down
11 changes: 8 additions & 3 deletions lib/agents/inquire.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,16 @@ export async function inquire(
maxTokens: 2500,
system: `You are a professional web researcher tasked with deepening your understanding of the user's input through further inquiries.
Only ask additional questions if absolutely necessary after receiving an initial response from the user.
'names' should be an array of English identifiers for the options provided. Structure your inquiry as follows:
Structure your inquiry as follows:
e.g., {
"inquiry": "What specific information are you seeking about Rivian?",
"options": ["History", "Products", "Investors", "Partnerships", "Competitors"],
"names": ["history", "products", "investors", "partnerships", "competitors"],
"options": [
{"value": "history", "label": "History"},
{"value": "products", "label": "Products"},
{"value": "investors", "label": "Investors"},
{"value": "partnerships", "label": "Partnerships"},
{"value": "competitors", "label": "Competitors"}
],
"allowsInput": true,
"inputLabel": "If other, please specify",
"inputPlaceholder": "e.g., Specifications"
Expand Down
2 changes: 1 addition & 1 deletion lib/schema/inquiry.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export const inquirySchema = z.object({
inquiry: z.string().describe(''),
options: z.array(
z.object({
name: z.string(),
value: z.string(),
label: z.string()
})
),
Expand Down

0 comments on commit 261325e

Please sign in to comment.