Question about 'Connect your own data'
yiouyou opened this issue · comments
Zack Song commented
Within 'Connect your own data' section, a workflow of hacker_news has been generated and needed to be running. My questions are:
- where to put the workflow file? save the following code somewhere?
path: /tmp/hn
embeddings:
path: sentence-transformers/all-MiniLM-L6-v2
content: true
tabular:
idcolumn: url
textcolumns:
- title
workflow:
index:
tasks:
- batch: false
extract:
- hits
method: get
params:
tags: null
task: service
url: https://hn.algolia.com/api/v1/search?hitsPerPage=50
- action: tabular
- action: index
writable: true
- how to run the workflow? save the following code somewhere then run it with python?
from txtai.app import Application
app = Application("index.yml")
list(app.workflow("index", ["front_page"]))
Thanks,