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

feat: add tagger(ai) to metadata worker #3135

Merged
merged 3 commits into from
Jun 17, 2023
Merged

feat: add tagger(ai) to metadata worker #3135

merged 3 commits into from
Jun 17, 2023

Conversation

bigint
Copy link
Member

@bigint bigint commented Jun 17, 2023

What does this PR do?

🤖 Generated by Copilot at a414a5f

This pull request enhances the metadata worker to use the @lenster/lens package and the Hugging Face API for generating publication metadata. It also updates the relevant files to include the new environment variable and dependency.

Related issues

Fixes # (issue)

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Enhancement (non-breaking small changes to existing functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Explanation of the changes

🤖 Generated by Copilot at a414a5f

  • Add HUGGINGFACE_API_KEY environment variable to authenticate requests to the Hugging Face API for natural language processing tasks (link, link)
  • Add dependency on @lenster/lens package to use types and utilities for publication metadata (link, link)
  • Import PublicationMetadataV2Input type from @lenster/lens package and annotate payload variable in postMetadata handler (link, link)
  • Call Hugging Face API with payload.content as input and store tags and entities in taggerResponseJson variable in postMetadata handler (link)
  • Include taggerResponseJson in the response payload of postMetadata handler (link)

Emoji

🔑📚🧠

@vercel
Copy link

vercel bot commented Jun 17, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
prerender ✅ Ready (Inspect) Visit Preview Jun 17, 2023 4:05pm
web ✅ Ready (Inspect) Visit Preview Jun 17, 2023 4:05pm

@vercel vercel bot temporarily deployed to Preview – prerender June 17, 2023 16:01 Inactive
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.

1 participant