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

add llamaindex + groq cookbook #503

Merged
merged 7 commits into from
May 16, 2024

Conversation

jerryjliu
Copy link
Contributor

same as #502 but with groq

@HamidShojanazeri
Copy link
Contributor

Thanks @jerryjliu for the PR can we pls add it here, under this folder, https://github.com/meta-llama/llama-recipes/tree/main/recipes/llama_api_providers

@jerryjliu
Copy link
Contributor Author

Thanks @jerryjliu for the PR can we pls add it here, under this folder, https://github.com/meta-llama/llama-recipes/tree/main/recipes/llama_api_providers

lol my bad! moving it now

@jerryjliu
Copy link
Contributor Author

@HamidShojanazeri check now

Copy link
Contributor

@jeffxtang jeffxtang left a comment

Choose a reason for hiding this comment

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

Thanks Jerry. Found a couple of errors while running the notebook. @jerryjliu

"source": [
"from llama_index.llms.groq import Groq\n",
"\n",
"llm = Groq(model=\"llama3-8b-8192\")\n",
Copy link
Contributor

Choose a reason for hiding this comment

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

should add
os.environ["GROQ_API_KEY"] = GROQ_API_KEY
or change to
llm = Groq(model="llama3-8b-8192", api_key=GROQ_API_TOKEN)

"source": [
"### Load Data\n",
"\n",
"We load data using LlamaParse by default, but you can also choose to opt for our free pypdf reader (in SimpleDirectoryReader by default) if you don't have an account."
Copy link
Contributor

Choose a reason for hiding this comment

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

Please add a note saying how to sign up to get a key. or uncomment the free one and comment the LlamaParse one. Also, is pypdf good enough? When should one use it and when LlamaParse? @jerryjliu

@jerryjliu jerryjliu requested a review from jeffxtang May 12, 2024 17:04
"metadata": {},
"outputs": [],
"source": [
"# from llama_index.core.query_engine import SubQuestionQueryEngine\n",
Copy link
Contributor

@jeffxtang jeffxtang May 12, 2024

Choose a reason for hiding this comment

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

remove these commented lines? or explain or uncomment? @jerryjliu I uncommented and running it got "ValueError: No valid JSON found in output"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@jeffxtang just tested again. for some reason i can't get sub-question to work on groq 70b, so i took the sub-question section out

@jerryjliu jerryjliu requested a review from jeffxtang May 13, 2024 00:47
"outputs": [],
"source": [
"drake_tool = QueryEngineTool(\n",
" drake_index.as_query_engine(),\n",
Copy link
Contributor

Choose a reason for hiding this comment

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

image

got an error @jerryjliu

@jeffxtang jeffxtang self-assigned this May 16, 2024
@jerryjliu jerryjliu requested a review from jeffxtang May 16, 2024 08:25
@jeffxtang jeffxtang merged commit 227fd59 into meta-llama:main May 16, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants