Find answers from the community

Updated 2 years ago

Is llama index adequate to teach openAI

Is llama_index adequate to "teach" openAI a new programming language ?
L
t
6 comments
Maybe! If all your documents in your index were examples of how to do basic things

You'd probably need to customize the prompt templates, but I could imagine asking stuff like "Write me a X language program that prints hello world"
I think one caveat is you'd want to keep each document example a little small, so it doesn't get split
Well, I've been trying these last days .. I've written documents explaining some concepts of the language (it's based on BASIC so it's not like it's Perl or anything) and giving syntax and examples.
Sometimes it will work quite well and openAI seems to follow the rules I wrote.
Then sometimes it's like it's forgetting the context and he invents new ways to do stuff ... looks like it's partially inspired by Python or JS syntax but it's hard to tell ...

Apart from the prompt, are there specific parameters that I should pay attention to ?
For now I'm using the simple SimpleDirectoryReader and GPTSimpleVectorIndex ... would I get better result with another kind of index ?

Also I tried with a langChain agent and it's slower and gives really poor results ...

Thanks for the answer, kinda new to all this ...
I would use a vector index as well, but you might want to increase similarity_top_k in the query

Also changing the text_qa_template and refine_template to have more specific instructions might help. They are currently very general
ok thanks I will try that ...
Add a reply
Sign up and join the conversation on Discord