Skip to content

geminiに対応#1

Open
Manchot13 wants to merge 8 commits intoYutoNose:mainfrom
Manchot13:feature/api-model-selection
Open

geminiに対応#1
Manchot13 wants to merge 8 commits intoYutoNose:mainfrom
Manchot13:feature/api-model-selection

Conversation

@Manchot13
Copy link

行ったこと

  • ask系にmodel_api_import_name変数を追加し、openaiとgeminiどちらかの入力によりそれぞれのモデルへと切り替えられるように
  • testの確認
  • exampleによる確認

確認

  • test,exampleが通るか

Copy link
Owner

@YutoNose YutoNose left a comment

Choose a reason for hiding this comment

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

ファイル分割だけお願い!

def _post_to_llm(messages: list[dict[str, str]], model_api_import_name: str) -> str:
"""
OpenAI ChatCompletion を呼び出して content 文字列を返す。
LLM APIを呼び出して content 文字列を返す。
Copy link
Owner

Choose a reason for hiding this comment

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

ここさ、将来的にモデルが増えるとllm.pyが非常に長くなってしまうので、dariko/modelsは以下にそれぞれgpt.py gemini.py claude.py...のようにファイル分割したい。それをお願いしてもいいかな?

@Manchot13
Copy link
Author

modelごとに別ファイルにできてなかったので、変更します

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