Code Monkey home page Code Monkey logo

Comments (7)

mrT23 avatar mrT23 commented on June 11, 2024

yes

https://pr-agent-docs.codium.ai/usage-guide/additional_configurations/#changing-a-model

from pr-agent.

mrT23 avatar mrT23 commented on June 11, 2024

In addition, in the near future, PR-Agent Pro would offer seamless support of claude3 along with GPT-4

from pr-agent.

ElonaZharri avatar ElonaZharri commented on June 11, 2024

I have llama2 running in my local, and I have made the necessary adjustments in .secrets.toml, configuration.toml and __init__.py, as specified here:

[__init__.py]
MAX_TOKENS={
    "ollama/llama2": 4096,
    ...,
}


[config] # in configuration.toml
model = "ollama/llama2"
model_turbo = "ollama/llama2"

[ollama] # in .secrets.toml
api_base = "http://localhost:11434/"

And this is the output I keep getting:

2024-04-17 16:11:29.179 | ERROR    | pr_agent.algo.utils:load_yaml:437 - Failed to parse AI prediction: mapping values are not allowed here
  in "<unicode string>", line 8, column 180:
     ... on in your `.pr_agent.toml` file:
                                         ^
2024-04-17 16:11:29.181 | INFO     | pr_agent.algo.utils:try_fix_yaml:459 - Failed to parse AI prediction after adding |-

2024-04-17 16:11:29.241 | INFO     | pr_agent.algo.utils:try_fix_yaml:488 - Successfully parsed AI prediction after removing 57 lines
2024-04-17 16:11:29.242 | ERROR    | pr_agent.tools.pr_reviewer:run:150 - Failed to review PR: 'str' object has no attribute 'get'

from pr-agent.

mrT23 avatar mrT23 commented on June 11, 2024

as the error message says, remove the '...', its a placeholder, not a real configuration

in addition, llama2 is a weak model for code, so your results probably wont be good

image

from pr-agent.

ElonaZharri avatar ElonaZharri commented on June 11, 2024

Thank you for your feedback. I did not have ... in __init__.py Attached are a few screenshots of the setup:

Screen Shot 2024-04-18 at 9 23 59 AM Screen Shot 2024-04-18 at 9 24 12 AM

Run again this morning:
Screen Shot 2024-04-18 at 9 34 08 AM

I agree, llama2 is weak, and I was wondering if I can use a custom llm provider, and use their API KEY token, instead of OpenAI.

from pr-agent.

barnett-yuxiang avatar barnett-yuxiang commented on June 11, 2024

pr-agent-docs.codium.ai/usage-guide/additional_configurations/#changing-a-model

from pr-agent.

mrT23 avatar mrT23 commented on June 11, 2024

closing this issues, as it was discussed and solve in the Discord channel

from pr-agent.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.