Web Analytics

proxyless-llm-websearch

⭐ 122 stars Vietnamese by itshyao

🌐 Ngôn ngữ

🧠 Công cụ tìm kiếm LLM không cần proxy

Một công cụ truy xuất thông tin web đa công cụ tìm kiếm LLM không cần proxy, hỗ trợ phân tích nội dung URL và thu thập dữ liệu trang web, kết hợp LangGraphLangGraph-MCP để xây dựng chuỗi tác tử mô-đun. Được thiết kế dành riêng cho các tình huống LLM cần truy xuất kiến thức bên ngoài, hỗ trợ Playwright + Crawl4AI để lấy và phân tích nội dung web, hỗ trợ bất đồng bộ, cắt nhỏ nội dung, lọc và xếp lại thứ tự.

🚀 Nhật ký cập nhật

✨ Tổng quan tính năng

workflow

framework

⚡ Bắt đầu nhanh

Clone kho lưu trữ

git clone https://github.com/itshyao/proxyless-llm-websearch.git
cd proxyless-llm-websearch

Cài đặt các phụ thuộc

pip install -r requirements.txt
python -m playwright install

Cấu hình biến môi trường

# 百炼llm
OPENAI_BASE_URL=https://dashscope.aliyuncs.com/compatible-mode/v1
OPENAI_API_KEY=sk-xxx
MODEL_NAME=qwen-plus-latest

百炼embedding

EMBEDDING_BASE_URL=https://dashscope.aliyuncs.com/compatible-mode/v1 EMBEDDING_API_KEY=sk-xxx EMBEDDING_MODEL_NAME=text-embedding-v4

百炼reranker

RERANK_BASE_URL=https://dashscope.aliyuncs.com/compatible-mode/v1 RERANK_API_KEY=sk-xxx RERANK_MODEL=gte-rerank-v2

Langgraph-Agent

#### TRÌNH DIỄN

python agent/demo.py

#### API PHỤC VỤ

python agent/api_serve.py

import requests

url = "http://localhost:8800/search"

data = { "question": "广州今日天气", "engine": "bing", "split": { "chunk_size": 512, "chunk_overlap": 128 }, "rerank": { "top_k": 5 } }

try: response = requests.post( url, json=data )

if response.status_code == 200: print("✅ 请求成功!") print("响应内容:", response.json()) else: print(f"❌ 请求失败,状态码:{response.status_code}") print("错误信息:", response.text)

except requests.exceptions.RequestException as e: print(f"⚠️ 请求异常:{str(e)}")

#### Gradio

python agent/gradio_demo.py

gradio

gradio

#### docker

docker-compose -f docker-compose-ag.yml up -d --build

Langgrph-MCP

#### Khởi động dịch vụ MCP

python mcp/websearch.py

#### TRÌNH DIỄN

python mcp/demo.py

#### API PHỤC VỤ

python mcp/api_serve.py

import requests

url = "http://localhost:8800/search"

data = { "question": "广州今日天气" }

try: response = requests.post( url, json=data )

if response.status_code == 200: print("✅ 请求成功!") print("响应内容:", response.json()) else: print(f"❌ 请求失败,状态码:{response.status_code}") print("错误信息:", response.text)

except requests.exceptions.RequestException as e: print(f"⚠️ 请求异常:{str(e)}")

#### docker

docker-compose -f docker-compose-mcp.yml up -d --build

Mô-đun tùy chỉnh

#### Phân khối tùy chỉnh

from typing import Optional, List

class YourSplitter: def __init__(self, text: str, chunk_size: int = 512, chunk_overlap: int = 128): self.text = text self.chunk_size = chunk_size self.chunk_overlap = chunk_overlap

def split_text(self, text: Optional[str] = None) -> List: # TODO: implement splitting logic return ["your chunk"]

#### Tùy chỉnh sắp xếp lại

from typing import List, Union, Tuple

class YourReranker: async def get_reranked_documents( self, query: Union[str, List[str]], documents: List[str], ) -> Union[ Tuple[List[str]], Tuple[List[int]], ]: return ["your chunk"], ["chunk index"]

🔍 So sánh với kiểm thử truy vấn mạng trực tuyến

Chúng tôi so sánh dự án với một số API trực tuyến chủ đạo, đánh giá hiệu suất của chúng với các câu hỏi phức tạp.

🔥 Bộ dữ liệu

🧑‍🏫 Kết quả so sánh

| Công cụ tìm kiếm/Hệ thống | ✅ Đúng | ❌ Sai | ⚠️ Đúng một phần | | ------------------------ | ------ | ------ | --------------- | | Volcano Ark | 5.00% | 72.21% | 22.79% | | BaiLian | 9.85% | 62.79% | 27.35% | | Our | 19.85% | 47.94% | 32.06% |

🙏 Lời cảm ơn

Một số chức năng của dự án này được hưởng lợi từ sự hỗ trợ và truyền cảm hứng của các dự án mã nguồn mở sau, xin trân trọng cảm ơn:

--- Tranlated By Open Ai Tx | Last indexed: 2025-09-08 ---