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

updated Readme #29

Merged
merged 3 commits into from
Dec 11, 2024
Merged

updated Readme #29

merged 3 commits into from
Dec 11, 2024

Conversation

adeelehsan
Copy link
Contributor

No description provided.

* Querying the corpora
```python
from vectara import SearchCorporaParameters, Vectara
client = Vectara(
Copy link
Collaborator

Choose a reason for hiding this comment

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

Perhaps explain here that you should use either the API Key or the OAUth ID/secret, but not both at the same time? on first read, that may be confusing to users.

README.md Outdated
)
```

* Starting the chat session
Copy link
Collaborator

Choose a reason for hiding this comment

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

Starting a chat session

)

response = session.chat(query="Tell me about machine learning.")
print(response.answer)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Here please show how someone does a subsequent chat. i.e. using the returned Chat session for a new turn

@adeelehsan
Copy link
Contributor Author

@ofermend please have a look again.

README.md Outdated
```python
from vectara import SearchCorporaParameters, Vectara
client = Vectara(
api_key="YOUR_API_KEY", # Use this for API key-based authentication
Copy link
Collaborator

Choose a reason for hiding this comment

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

This is better but not ideal still. My recommendation is:

  1. Have a section about "create a client" that just shows the client=Vectara() piece, and shows it in two different ways (not a single call with "OR" comment - that can be confusing).
  2. Then show query (i.e. setup search params, generation params, and the query). But please add some parameters there as an example. IT needs to be a good example where someone can copy/paste and get good results. You can then suggest they can look at docs for more details and options.
  3. Chat example.

README.md Outdated
chat_params = ChatParameters(store=True)

session = client.create_chat_session(
search=search_params,
Copy link
Collaborator

Choose a reason for hiding this comment

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

shouldn't this be search=search and generation=generation? (search_params is not defined).
Please make these real examples and test them to validate.

Copy link
Collaborator

@ofermend ofermend left a comment

Choose a reason for hiding this comment

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

LGTM.
There are a few minor things in formattting, but let's merge and I can do a small PR to fix later.

@adeelehsan adeelehsan merged commit bed4453 into main Dec 11, 2024
3 checks passed
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