Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Select language models for agents #111

Merged
merged 1 commit into from
Jul 30, 2024
Merged

Select language models for agents #111

merged 1 commit into from
Jul 30, 2024

Conversation

tortmayr
Copy link

@tortmayr tortmayr commented Jul 30, 2024

Issue: https://github.com/eclipsesource/osweek-2024/issues/42

Follow-up with known issues and improvements: https://github.com/eclipsesource/osweek-2024/issues/59

What it does

  • Add section for re-configuring agent purposes ( i.e language model for a specific purpose)
  • Introduce AISettingService service to retrieve and configure AI settings for a specific agent.
  • Use Theia preferences as a storage sytem for the AI settings
  • Add temporary languageModelRequirements to the DefaultChatAgent?
  • Implement LanguageModelRegistry.selectLanguageModel method for the fronted language model registry

How to test

  • Open the AI Settings view from the Open view... menu
  • The view will display a list of all the available agents (currently only the Chat agent exists) and their properties
  • Select one of the available purposes of the Agent
  • Select one of the available language models
  • The Language model selection should be persisted in the Theia preferences
  • The Agent should use the selected model
demo.mp4

@tortmayr tortmayr changed the title iIssue 42 Select language models for agents Jul 30, 2024
@tortmayr tortmayr marked this pull request as ready for review July 30, 2024 09:00
@jfaltermeier jfaltermeier self-requested a review July 30, 2024 09:14
@jfaltermeier
Copy link

jfaltermeier commented Jul 30, 2024

Besides the known issues from the follow up: when I just switch the purpose, the preference is not updated:
Peek 2024-07-30 11-38

@sdirix sdirix self-requested a review July 30, 2024 09:39
Copy link
Member

@sdirix sdirix left a comment

Choose a reason for hiding this comment

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

I merged the PR into our code-completion PR. It works and I can select the language model for all our requests. Nice!

Copy link

@jfaltermeier jfaltermeier left a comment

Choose a reason for hiding this comment

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

Besides that I did not find a further issue, so imo we may merge this and add above comment to the follow up.

this.update();
}
private onSelectedPurposesChange(agentId: string, event: React.ChangeEvent<HTMLSelectElement>): void {
this.selectedPurposes.set(agentId, event.target.value);
this.update();

Choose a reason for hiding this comment

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

This should probably try to update the preferences as well, but this can be done in a follow up.

@AlexandraBuzila AlexandraBuzila merged commit 565954e into feat/ai-chat Jul 30, 2024
1 check passed
@sdirix sdirix deleted the issue-42 branch July 30, 2024 09:57
@tortmayr tortmayr mentioned this pull request Jul 30, 2024
1 task
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.

4 participants