wiseflow/core
2024-08-06 23:11:25 +08:00
..
insights add summary to url-info 2024-08-04 18:26:58 +08:00
llms code review 2024-06-14 09:08:12 +08:00
pb add scripts 2024-06-20 15:01:27 +08:00
scrapers update mp_crawler 2024-07-30 22:32:48 +08:00
scripts Fix typo (#28) 2024-08-06 23:11:25 +08:00
utils Fix typo (#28) 2024-08-06 23:11:25 +08:00
backend.py update README 2024-06-21 10:05:33 +08:00
docker_entrypoint.sh add scripts 2024-06-20 15:01:27 +08:00
README.md fix mistake 2024-06-27 09:20:12 +08:00
requirements.txt add scripts 2024-06-20 15:01:27 +08:00
tasks.py fix url-repeat and some img path miss base-url 2024-06-22 16:47:13 +08:00

For Developer Only

conda create -n wiseflow python=3.10
conda activate wiseflow
cd core
pip install -r requirements.txt
  • tasks.py background task circle process
  • backend.py main process pipeline service (based on fastapi)

WiseFlow fastapi detail

{'user_id': str, 'type': str, 'content':str, 'addition': Optional[str]}
# Type is one of "text", "publicMsg", "site" and "url"
# user_id: str
type: Literal["text", "publicMsg", "file", "image", "video", "location", "chathistory", "site", "attachment", "url"]
content: str
addition: Optional[str] = None

see more (when backend started) http://127.0.0.1:8077/docs

WiseFlow Repo File Structure

wiseflow
|- dockerfiles
|- ...
|- core
    |- tasks.py
    |- backend.py
    |- insights
        |- __init__.py  # main process
        |- get_info.py  # module use llm to get a summary of information and match tags
    |- llms # llm service wrapper
    |- pb  # pocketbase filefolder
    |- scrapers
        |- __init__.py  # You can register a proprietary site scraper here
        |- general_scraper.py  # module to get all possible article urls for general site 
        |- general_crawler.py  # module for general article sites
        |- mp_crawler.py  # module for mp article (weixin public account) sites
   |- utils # tools

Although the general_scraper included in wiseflow can be applied to the parsing of most static pages, for actual business, we still recommend that customers to write their own crawlers aiming the actual info source.

See core/scrapers/README.md for integration instructions for proprietary crawlers