Content-Length: 269223 | pFad | http://github.com/tgbot-collection/SearchGram/commit/48605ca617963aa42de6b072a3f8ef37db659471

3A add zinc · tgbot-collection/SearchGram@48605ca · GitHub
Skip to content

Commit

Permalink
add zinc
Browse files Browse the repository at this point in the history
  • Loading branch information
BennyThink committed Nov 18, 2023
1 parent e7a9eab commit 48605ca
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 0 deletions.
13 changes: 13 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,16 @@ services:
driver: none
ports:
- "127.0.0.1:27017:27017"

zincsearch:
image: public.ecr.aws/zinclabs/zincsearch:latest
ports:
- "127.0.0.1:4080:4080"
environment:
ZINC_DATA_PATH: "/data"
# ZINC_FIRST_ADMIN_USER: "admin"
# ZINC_FIRST_ADMIN_PASSWORD: "Complexpass#123"
env_file:
- env/gram.env
volumes:
- ./sg_data/:/data
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ meilisearch==0.28.1
coloredlogs==15.0.1
pymongo==4.6.0
zhconv==1.4.3
zincsearch-sdk==0.3.3
26 changes: 26 additions & 0 deletions searchgram/zinc.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#!/usr/bin/env python3
# coding: utf-8

# SearchGram - zinc.py
# 2023-11-18 18:04

from utils import sizeof_fmt
import zincsearch_sdk
from engine import BasicSearchEngine


class SearchEngine(BasicSearchEngine):
def upsert(self, message):
if self.check_ignore(message):
return
data = self.set_uid(message)
# self.client.index("telegram").add_documents([data], primary_key="ID")

def search(self, keyword, _type=None, user=None, page=1, mode=None) -> dict:
pass

def ping(self) -> str:
pass

def clear_db(self):
pass

0 comments on commit 48605ca

Please sign in to comment.








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/tgbot-collection/SearchGram/commit/48605ca617963aa42de6b072a3f8ef37db659471

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy