Skip to content

Conversation

@maxwelljin
Copy link
Contributor

This PR integrates improvements for the document based on Han's suggestions from our Discord channel:

  1. Typos in the document vector code have been corrected.
  2. The text layout has been optimized for better readability.
  3. Example code for Fast API has been incorporated to provide more hands-on guidance.

Signed-off-by: maxwelljin <101249253+maxwelljin@users.noreply.github.com>
Signed-off-by: maxwelljin <101249253+maxwelljin@users.noreply.github.com>
Signed-off-by: maxwelljin <101249253+maxwelljin@users.noreply.github.com>
@maxwelljin maxwelljin marked this pull request as ready for review June 19, 2023 08:50
README.md Outdated

app = FastAPI()

model_img, model_text = SomeEmbeddingModelImage(), SomeEmbeddingModelText()
Copy link
Member

Choose a reason for hiding this comment

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

I prefer to have a def embed_image and def embed_text method with random numpy array generation, it is easier to reproduce

return doc


async with AsyncClient(app=app, base_url="http://test") as ac:
Copy link
Member

Choose a reason for hiding this comment

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

why are u removing this?

Signed-off-by: maxwelljin <101249253+maxwelljin@users.noreply.github.com>
@maxwelljin maxwelljin requested a review from JoanFM June 19, 2023 09:01
README.md Outdated
app = FastAPI()

model_img, model_text = SomeEmbeddingModelImage(), SomeEmbeddingModelText()
model_img, model_text = lambda img: np.zeros((100, 1)), lambda text: np.zeros((100, 1))
Copy link
Member

Choose a reason for hiding this comment

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

lets use a def and not lambda, easier to read

Signed-off-by: maxwelljin <101249253+maxwelljin@users.noreply.github.com>
@maxwelljin maxwelljin requested a review from JoanFM June 19, 2023 10:00
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