repo_full_name
stringlengths
6
93
repo_url
stringlengths
25
112
repo_api_url
stringclasses
28 values
owner
stringclasses
28 values
repo_name
stringclasses
28 values
description
stringclasses
28 values
stars
int64
617
98.8k
forks
int64
31
355
watchers
int64
990
999
license
stringclasses
2 values
default_branch
stringclasses
2 values
repo_created_at
timestamp[s]date
2012-07-24 23:12:50
2025-06-16 08:07:28
repo_updated_at
timestamp[s]date
2026-02-23 15:23:15
2026-05-03 18:52:12
repo_topics
listlengths
0
13
repo_languages
unknown
is_fork
bool
1 class
open_issues
int64
3
104
file_path
stringlengths
3
208
file_name
stringclasses
509 values
file_extension
stringclasses
1 value
file_size_bytes
int64
101
84k
file_url
stringclasses
627 values
file_raw_url
stringclasses
627 values
file_sha
stringclasses
624 values
language
stringclasses
8 values
parsed_at
stringdate
2026-05-04 01:12:36
2026-05-04 19:41:55
text
stringlengths
100
102k
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/audio_eval.py
null
null
null
null
null
null
Python
2026-05-04T02:45:27.515743
import torch from datasets import load_dataset from evaluate import load from pipelines.whisper import SpeechToTextPipeline from tqdm import tqdm from transformers import AutoModelForSpeechSeq2Seq, AutoProcessor, BitsAndBytesConfig, HqqConfig, pipeline from transformers.pipelines.pt_utils import KeyDataset model_id = ...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/cli.py
null
null
null
null
null
null
Python
2026-05-04T02:45:27.530202
from fire import Fire from whisperplus import __version__ as whisperplus_version whisperplus_app = {"version": whisperplus_version} def app(): Fire(whisperplus_app) if __name__ == "__main__": app()
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/lancedb_chatbot.py
null
null
null
null
null
null
Python
2026-05-04T02:45:27.531410
import logging import lancedb from langchain.chains import RetrievalQA from langchain.document_loaders import TextLoader from langchain.embeddings import HuggingFaceEmbeddings from langchain.llms import CTransformers from langchain.prompts import PromptTemplate from langchain.text_splitter import RecursiveCharacterTex...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
setup.py
null
null
null
null
null
null
Python
2026-05-04T02:45:27.540445
import os import re import setuptools def get_requirements(req_path: str): with open(req_path, encoding='utf8') as f: return f.read().splitlines() INSTALL_REQUIRES = get_requirements("requirements.txt") def get_long_description(): base_dir = os.path.abspath(os.path.dirname(__file__)) with ope...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/autollm_chatbot.py
null
null
null
null
null
null
Python
2026-05-04T02:45:27.540961
import logging import os from typing import Optional import torch from autollm import AutoQueryEngine, read_files_as_documents # Configure basic logging logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s') logger = logging.getLogger(__name__) class AutoLLMChatWithVideo: d...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/__init__.py
null
null
null
null
null
null
Python
2026-05-04T02:45:27.575461
# from whisperplus.pipelines.autollm_chatbot import AutoLLMChatWithVideo # from whisperplus.pipelines.long_text_summarization import LongTextSummarizationPipeline # from whisperplus.pipelines.summarization import TextSummarizationPipeline # from whisperplus.pipelines.text2speech import TextToSpeechPipeline from whisper...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
scripts/package.py
null
null
null
null
null
null
Python
2026-05-04T02:45:27.576526
import subprocess def run_command(command): """ Executes a given command using the subprocess module. Args: command (str): The command to be executed. """ subprocess.run(command, shell=True, check=True) def main(): """Main function to package and upload a Python package using setup....
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/lightning_whisper_mlx/load_models.py
null
null
null
null
null
null
Python
2026-05-04T02:45:28.364678
# Copyright © 2023 Apple Inc. import json from pathlib import Path import mlx.core as mx import mlx.nn as nn from huggingface_hub import snapshot_download from mlx.utils import tree_unflatten from . import whisper def load_model( path_or_hf_repo: str, dtype: mx.Dtype = mx.float32, ) -> whisper.Whisper: ...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/lightning_whisper_mlx/timing.py
null
null
null
null
null
null
Python
2026-05-04T02:45:28.366291
# Copyright © 2023 Apple Inc. import itertools from dataclasses import dataclass from typing import TYPE_CHECKING, List import mlx.core as mx import numba import numpy as np from scipy import signal from .audio import HOP_LENGTH, SAMPLE_RATE, TOKENS_PER_SECOND from .tokenizer import Tokenizer if TYPE_CHECKING: ...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/lightning_whisper_mlx/transcribe.py
null
null
null
null
null
null
Python
2026-05-04T02:45:28.367463
# Copyright © 2023 Apple Inc. import sys import time import warnings from typing import List, Optional, Tuple, Union import mlx.core as mx import numpy as np import tqdm from .audio import ( FRAMES_PER_SECOND, HOP_LENGTH, N_FRAMES, N_SAMPLES, SAMPLE_RATE, log_mel_spectrogram, pad_or_trim,...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/lightning_whisper_mlx/decoding.py
null
null
null
null
null
null
Python
2026-05-04T02:45:28.368627
# Copyright © 2023 Apple Inc. import zlib from dataclasses import dataclass, field, replace from typing import Dict, Iterable, List, Optional, Sequence, Tuple, Union import mlx.core as mx import mlx.nn as nn import numpy as np from mlx.utils import tree_map from .audio import CHUNK_LENGTH from .tokenizer import Toke...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/lightning_whisper_mlx/tokenizer.py
null
null
null
null
null
null
Python
2026-05-04T02:45:28.471004
# Copyright © 2023 Apple Inc. import base64 import os import string from dataclasses import dataclass, field from functools import cached_property, lru_cache from typing import Dict, List, Optional, Tuple import tiktoken LANGUAGES = { "en": "english", "zh": "chinese", "de": "german", "es": "spanish",...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/lightning_whisper_mlx/lightning.py
null
null
null
null
null
null
Python
2026-05-04T02:45:28.579593
from huggingface_hub import hf_hub_download from .transcribe import transcribe_audio models = { "tiny": { "base": "mlx-community/whisper-tiny", "4bit": "mlx-community/whisper-tiny-mlx-4bit", "8bit": "mlx-community/whisper-tiny-mlx-8bit" }, "small": { "base": "mlx-community/...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/long_text_summarization.py
null
null
null
null
null
null
Python
2026-05-04T02:45:28.985993
import logging import torch from transformers import AutoTokenizer, pipeline logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s') class LongTextSummarizationPipeline: def __init__(self, model_id: str = "facebook/bart-large-cnn"): logging.info("Initializing Text Su...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/lightning_whisper_mlx/torch_whisper.py
null
null
null
null
null
null
Python
2026-05-04T02:45:29.091363
# Copyright © 2023 Apple Inc. import base64 import gzip from dataclasses import dataclass from typing import Dict, Iterable, Optional import numpy as np import torch import torch.nn.functional as F from torch import Tensor, nn @dataclass class ModelDimensions: n_mels: int n_audio_ctx: int n_audio_state:...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/lightning_whisper_mlx/audio.py
null
null
null
null
null
null
Python
2026-05-04T02:45:29.110239
# Copyright © 2023 Apple Inc. import os from functools import lru_cache from subprocess import CalledProcessError, run from typing import Optional, Union import mlx.core as mx import numpy as np # hard-coded audio hyperparameters SAMPLE_RATE = 16000 N_FFT = 400 HOP_LENGTH = 160 CHUNK_LENGTH = 30 N_SAMPLES = CHUNK_LE...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/lightning_whisper_mlx/whisper.py
null
null
null
null
null
null
Python
2026-05-04T02:45:29.260288
# Copyright © 2023 Apple Inc. import base64 import gzip import math from dataclasses import dataclass from typing import Union import mlx.core as mx import mlx.nn as nn import numpy as np from .decoding import decode as decode_function from .decoding import detect_language as detect_language_function @dataclass cl...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/load_models.py
null
null
null
null
null
null
Python
2026-05-04T02:45:29.383351
# Copyright © 2023 Apple Inc. import json from pathlib import Path import mlx.core as mx import mlx.nn as nn from huggingface_hub import snapshot_download from mlx.utils import tree_unflatten from . import whisper def load_model( path_or_hf_repo: str, dtype: mx.Dtype = mx.float32, ) -> whisper.Whisper: ...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/timing.py
null
null
null
null
null
null
Python
2026-05-04T02:45:29.559378
# Copyright © 2023 Apple Inc. import itertools from dataclasses import dataclass from typing import TYPE_CHECKING, List import mlx.core as mx import numba import numpy as np from scipy import signal from .audio import HOP_LENGTH, SAMPLE_RATE, TOKENS_PER_SECOND from .tokenizer import Tokenizer if TYPE_CHECKING: ...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/torch_whisper.py
null
null
null
null
null
null
Python
2026-05-04T02:45:29.650686
# Copyright © 2023 Apple Inc. import base64 import gzip from dataclasses import dataclass from typing import Dict, Iterable, Optional import numpy as np import torch import torch.nn.functional as F from torch import Tensor, nn @dataclass class ModelDimensions: n_mels: int n_audio_ctx: int n_audio_state:...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/tokenizer.py
null
null
null
null
null
null
Python
2026-05-04T02:45:29.664641
# Copyright © 2023 Apple Inc. import base64 import os import string from dataclasses import dataclass, field from functools import cached_property, lru_cache from typing import Dict, List, Optional, Tuple import tiktoken LANGUAGES = { "en": "english", "zh": "chinese", "de": "german", "es": "spanish",...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/transcribe.py
null
null
null
null
null
null
Python
2026-05-04T02:45:29.792106
# Copyright © 2023 Apple Inc. import sys import warnings from typing import List, Optional, Tuple, Union import mlx.core as mx import numpy as np import tqdm from .audio import ( FRAMES_PER_SECOND, HOP_LENGTH, N_FRAMES, N_SAMPLES, SAMPLE_RATE, log_mel_spectrogram, pad_or_trim, ) from .dec...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/__init__.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.033786
# Copyright © 2023-2024 Apple Inc. from . import audio, decoding, load_models from .transcribe import transcribe from .version import __version__
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/benchmark.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.066982
# Copyright © 2023-2024 Apple Inc. import argparse import os import time import mlx.core as mx from mlx_whisper import audio, decoding, load_models, transcribe audio_file = "mlx_whisper/assets/ls_test.flac" def parse_arguments(): parser = argparse.ArgumentParser(description="Benchmark script.") parser.add_a...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/audio.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.086438
# Copyright © 2023 Apple Inc. import os from functools import lru_cache from subprocess import CalledProcessError, run from typing import Union import mlx.core as mx import numpy as np # hard-coded audio hyperparameters SAMPLE_RATE = 16000 N_FFT = 400 HOP_LENGTH = 160 CHUNK_LENGTH = 30 N_SAMPLES = CHUNK_LENGTH * SAM...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/whisper.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.172707
# Copyright © 2023 Apple Inc. import base64 import gzip import math from dataclasses import dataclass from typing import Union import mlx.core as mx import mlx.nn as nn import numpy as np from .decoding import decode as decode_function from .decoding import detect_language as detect_language_function @dataclass cl...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/convert.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.173946
# Copyright © 2023-2024 Apple Inc. import argparse import copy import hashlib import json import os import urllib import warnings from dataclasses import asdict from pathlib import Path from typing import List import mlx.core as mx import mlx.nn as nn import numpy as np import torch from mlx.utils import tree_flatten...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/summarization.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.190606
import logging import torch from transformers import pipeline logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s') class TextSummarizationPipeline: def __init__(self, model_id: str = "facebook/bart-large-cnn"): logging.info("Initializing Text Summarization Pipelin...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/text2speech.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.208858
# Author: @GuldenizBektas # ignore [E265] import logging import torch from scipy.io.wavfile import write as write_wav from transformers import AutoModelForTextToWaveform, AutoProcessor class TextToSpeechPipeline: """Class to convert text to speech.""" def __init__(self, model_id: str = "suno/bark"): ...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/whisper.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.380296
import logging from typing import Optional import torch from transformers import AutoModelForSpeechSeq2Seq, AutoProcessor, pipeline logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s') class SpeechToTextPipeline: """Class for converting audio to text using a pre-trained sp...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/whisper_autocaption.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.522258
import logging import tempfile import ffmpeg import torch from moviepy import CompositeVideoClip, TextClip, VideoFileClip from transformers import AutoModelForSpeechSeq2Seq, AutoProcessor, pipeline logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s') class WhisperAutoCaptionPi...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/whisper_diarize.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.592798
from typing import List, Optional, Union import numpy as np import requests import torch from pyannote.audio import Pipeline from torchaudio import functional as F from transformers import pipeline from transformers.pipelines.audio_utils import ffmpeg_read class ASRDiarizationPipeline: def __init__( sel...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/test.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.652782
import torch from pipelines.whisper import SpeechToTextPipeline from transformers import BitsAndBytesConfig, HqqConfig from utils.download_utils import download_youtube_to_mp3 url = "https://www.youtube.com/watch?v=BpN4hEAvDBg" audio_path = download_youtube_to_mp3(url) hqq_config = HqqConfig( nbits=4, group_s...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/utils/download_utils.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.734226
import logging from pathlib import Path import yt_dlp logging.basicConfig(level=logging.INFO, format='%(asctime)s [%(levelname)s] %(message)s') def download_youtube_to_mp3(url, output_dir='./', filename="test"): """ Downloads a YouTube video as an MP3 file. Parameters: url (str): The URL of the You...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/utils/text_utils.py
null
null
null
null
null
null
Python
2026-05-04T02:45:30.738080
def format_speech_to_dialogue(speech_text): """ Formats the given text into a dialogue format. Args: speech_text (str): The dialogue text to be formatted. Returns: str: Formatted text in dialogue format. """ # Parse the given text appropriately dialog_list = eval(str(speech...
kadirnar/whisper-plus
https://github.com/kadirnar/whisper-plus
null
null
null
null
1,949
null
null
apache-2.0
null
null
null
null
null
null
null
whisperplus/pipelines/mlx_whisper/decoding.py
null
null
null
null
null
null
Python
2026-05-04T02:45:34.189081
# Copyright © 2023 Apple Inc. import zlib from dataclasses import dataclass, field, replace from typing import Dict, Iterable, List, Optional, Sequence, Tuple, Union import mlx.core as mx import numpy as np from mlx.utils import tree_map from .audio import CHUNK_LENGTH from .tokenizer import Tokenizer, get_tokenizer...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/ai_integration/ai_provider_factory.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.014378
from typing import Optional, Dict, Any from .kimi_adapter import KimiAdapter from .qwen_adapter import QwenAdapter class AIProviderFactory: """AI服务提供商工厂""" PROVIDERS = { 'kimi': { 'name': 'Kimi AI', 'description': '月之暗面Kimi大模型', 'adapter': KimiAdapter, ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
main.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.015700
import logging import os import signal import sys from PyQt5.QtCore import QTimer from PyQt5.QtGui import QIcon from PyQt5.QtWidgets import (QApplication, QHBoxLayout, QMainWindow, QPushButton, QStackedWidget, QVBoxLayout, QWidget) from src.config.config import Config from src.core.brow...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/config/database.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.019859
import os from sqlalchemy import create_engine from sqlalchemy.orm import sessionmaker from sqlalchemy.pool import StaticPool from typing import Generator # 使用统一的模型 Base(避免出现创建表/查询表不一致) from src.core.models import Base class DatabaseManager: """数据库管理器""" def __init__(self): # 获取用户主目录 h...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
scripts/xhs_login_cli.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.067271
#!/usr/bin/env python3 from __future__ import annotations import argparse import asyncio import os import sys ROOT = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) if ROOT not in sys.path: sys.path.insert(0, ROOT) from src.core.write_xiaohongshu import XiaohongshuPoster async def _main() -> int: ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/config/config.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.068746
import json import os class Config: """配置管理类""" def __init__(self): # 获取用户主目录 home_dir = os.path.expanduser('~') # 创建应用配置目录 app_config_dir = os.path.join(home_dir, '.xhs_system') if not os.path.exists(app_config_dir): os.makedirs(app_config_dir)...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/ai_integration/qwen_adapter.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.165161
import requests import json import time from typing import Dict, Optional, List class QwenAdapter: """通义千问AI图片生成适配器""" def __init__(self, api_key: str): self.api_key = api_key self.base_url = "https://dashscope.aliyuncs.com/api/v1" self.headers = { "Authorization": f"Be...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/ai_integration/api_key_manager.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.172630
import os import json from typing import Dict, Optional from cryptography.fernet import Fernet import base64 class APIKeyManager: """用户API密钥管理器 - 本地加密存储""" def __init__(self): self.keys_dir = os.path.expanduser('~/.xhs_system') self.keys_file = os.path.join(self.keys_dir, 'keys.enc') ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/ai_integration/kimi_adapter.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.173860
import requests import json import time from typing import Dict, Optional, List class KimiAdapter: """Kimi AI图片生成适配器""" def __init__(self, api_key: str): self.api_key = api_key self.base_url = "https://api.moonshot.cn/v1" self.headers = { "Authorization": f"Bearer {api_...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/alert.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.553673
import sys from PyQt5.QtWidgets import (QWidget, QVBoxLayout, QHBoxLayout, QLabel, QPushButton, QFrame, QProgressBar, QGraphicsView, QGraphicsScene, QGraphicsDropShadowEffect) from PyQt5.QtCore import Qt, QTimer from PyQt5.QtG...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/auth_manager.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.575486
import asyncio import json import os import time from typing import Optional, Dict, Any from pathlib import Path from .logger import logger from .config import config class AuthManager: """认证管理器 - 处理登录、登出和认证状态管理""" def __init__(self): self.browser_manager = None self.poster = None ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/browser.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.585424
from PyQt5.QtCore import QThread, pyqtSignal import asyncio import os import random import re import sys import time from functools import partial from src.core.write_xiaohongshu import XiaohongshuPoster class BrowserThread(QThread): # 添加信号 login_status_changed = pyqtSignal(str, bool) # 用于更新登录按钮状态 previ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/browser_manager.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.587299
import asyncio import os import sys from contextlib import asynccontextmanager from playwright.async_api import async_playwright, Browser, BrowserContext, Page from typing import Optional, Dict, Any from .logger import logger from .config import config class BrowserManager: """浏览器管理器 - 使用上下文管理器确保资源正确释放"""...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/config.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.601198
import os import json from typing import Dict, Any, Optional from dataclasses import dataclass, asdict from pathlib import Path def _env_flag(name: str, default: bool) -> bool: value = os.getenv(name, "").strip().lower() if not value: return default if value in {"1", "true", "yes", "y", "on"}: ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/content_manager.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.677951
import os import json import time from typing import List, Dict, Any, Optional, Tuple from pathlib import Path from dataclasses import dataclass, asdict from datetime import datetime import hashlib import mimetypes from .logger import logger from .config import config @dataclass class ContentItem: ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/content_publisher.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.688563
from __future__ import annotations from typing import List, Optional from .browser_manager import BrowserManager from .write_xiaohongshu import XiaohongshuPoster class ContentPublisher: """兼容层:为 V2 调用方复用现有发布实现。""" def __init__(self): self.browser_manager: Optional[BrowserManager] = None sel...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/enhanced_browser_manager.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.732462
import asyncio import os import sys from contextlib import asynccontextmanager from playwright.async_api import async_playwright, Browser, BrowserContext, Page from typing import Optional, Dict, Any from .logger import logger from .services.user_service import user_service from .services.proxy_service import ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/database_manager.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.769596
#!/usr/bin/env python3 """ 数据库管理器 集成数据库初始化、修复、健康检查功能 """ import os import sqlite3 import shutil from pathlib import Path from typing import Optional, List, Dict, Any from datetime import datetime class DatabaseManager: """数据库管理器类""" def __init__(self): # 获取用户主目录 self.h...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/database_init.py
null
null
null
null
null
null
Python
2026-05-04T02:45:37.770909
""" 数据库初始化脚本 用于创建表结构和初始化基础数据 """ import os import sys from sqlalchemy import create_engine, text from sqlalchemy.exc import SQLAlchemyError # 添加项目根目录到路径 project_root = os.path.dirname(os.path.dirname(os.path.dirname(os.path.abspath(__file__)))) sys.path.insert(0, project_root) from src.config.database ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/generation/__init__.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.100628
# 小红书AI图片生成核心模块 from .content_analyzer import ContentAnalyzer, ContentAnalysis from .style_selector import StyleSelector, StyleType, StyleConfig from .prompt_builder import PromptBuilder, PromptTemplate __all__ = [ 'ContentAnalyzer', 'ContentAnalysis', 'StyleSelector', 'StyleType', 'StyleConfig',...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/generation/cover_text_generator.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.128252
""" AI封面文字生成器 根据内容自动生成适合的封面标题和文案 """ import json import re from typing import Dict, List, Optional, Tuple from ..ai_integration.ai_provider_factory import AIProviderFactory class CoverTextGenerator: """AI封面文字生成器""" def __init__(self): # 暂时使用模拟AI服务,实际使用时需要配置API密钥 self.ai_p...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/generation/content_analyzer.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.157161
import re from typing import Dict, List, Optional, Tuple from dataclasses import dataclass @dataclass class ContentAnalysis: """内容分析结果""" title: str topics: List[str] keywords: List[str] sentiment: str target_audience: str image_type: str # 'cover' or 'content' color_scheme: str st...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/generation/style_selector.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.158155
from typing import Dict, List, Optional, Tuple from dataclasses import dataclass from enum import Enum class StyleType(Enum): """风格类型枚举""" CUTE = "cute" CLEAN = "clean" PROFESSIONAL = "professional" TRENDY = "trendy" WARM = "warm" ELEGANT = "elegant" MINIMAL = "minimal" VINTAGE = "v...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/generation/prompt_builder.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.199176
from typing import Dict, List, Optional, Any from dataclasses import dataclass import json @dataclass class PromptTemplate: """提示词模板""" name: str description: str template: str parameters: Dict[str, Any] examples: List[str] class PromptBuilder: """小红书AI图片生成提示词构建器""" def __init__(s...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/importers/webpage_article.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.262285
from __future__ import annotations import re from dataclasses import dataclass, field from html.parser import HTMLParser from typing import Dict, List, Optional, Tuple from urllib.parse import urljoin, urlparse import requests @dataclass class WebpageArticle: url: str title: str content_text: str im...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/importers/wechat_article.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.282294
from __future__ import annotations import re from dataclasses import dataclass, field from html.parser import HTMLParser from typing import Dict, List, Optional, Tuple import requests @dataclass class WechatArticle: url: str title: str content_text: str image_urls: List[str] = field(default_factory=...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/logger.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.351917
import logging import os from datetime import datetime from typing import Optional class Logger: """统一的日志管理器""" def __init__(self, name: str = "xiaohongshu", log_dir: str = None): self.logger = logging.getLogger(name) self.logger.setLevel(logging.DEBUG) # 避免重复添...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/models/__init__.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.368875
""" 数据模型包初始化文件 包含所有数据模型类的导入 """ # 从user模块导入Base和所有模型类 from .user import Base, User, ProxyConfig, BrowserFingerprint from .browser_environment import BrowserEnvironment from .content import ContentTemplate, PublishHistory, ScheduledTask from .cover_template import CoverTemplate # 公开的模型接口 __all__ = [ '...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/models/browser_environment.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.694900
""" 浏览器环境配置模型 包含代理配置、浏览器指纹等完整环境信息 """ from datetime import datetime from sqlalchemy import Column, Integer, String, Boolean, DateTime, Text, ForeignKey, Float, JSON from sqlalchemy.orm import relationship # 从user.py导入共享的Base from .user import Base class BrowserEnvironment(Base): """浏览器环境配置模型(合并代理和...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/models/content.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.695563
""" 内容管理相关数据模型 包含内容模板、发布历史、定时任务等模型 """ from datetime import datetime from sqlalchemy import Column, Integer, String, Boolean, DateTime, Text, ForeignKey, JSON from sqlalchemy.orm import relationship # 从user模块导入Base from .user import Base class ContentTemplate(Base): """内容模板模型""" __tablename__...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/models/cover_template.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.697139
from sqlalchemy import Column, Integer, String, Text, DateTime, Boolean, JSON from datetime import datetime from .user import Base class CoverTemplate(Base): __tablename__ = 'cover_templates' id = Column(Integer, primary_key=True, autoincrement=True) name = Column(String(100), nullable=False, comm...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/models/user.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.754753
""" 用户相关数据模型 包含用户、代理配置、浏览器指纹等模型 """ from datetime import datetime from sqlalchemy import Column, Integer, String, Boolean, DateTime, Text, ForeignKey, Float from sqlalchemy.orm import relationship, declarative_base # 创建基类(这里直接创建,避免循环导入) Base = declarative_base() class User(Base): """用户模型""" __ta...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/ai_cover_page.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.775376
#!/usr/bin/env python3 """ AI封面生成页面 支持AI文字生成和动态贴图到模板 """ import os import json from PyQt5.QtCore import Qt, QThread, pyqtSignal from PyQt5.QtGui import QPixmap, QFont, QIcon from PyQt5.QtWidgets import (QWidget, QVBoxLayout, QHBoxLayout, QLabel, QPushButton, QScrollArea, QFrame, ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/browser_environment_page.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.844102
#!/usr/bin/env python3 """ 浏览器环境管理页面 - 合并代理和指纹配置 """ import json from PyQt5.QtCore import Qt, pyqtSignal from PyQt5.QtGui import QFont from PyQt5.QtWidgets import (QWidget, QVBoxLayout, QHBoxLayout, QLabel, QPushButton, QTableWidget, QTableWidgetItem, Q...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/cover_center_page.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.912834
#!/usr/bin/env python3 """ 封面中心页面:封面模板库(仅选择) - 模板库:展示系统封面模板(showcase_*.png) - 选择后:保存为“首页生成封面”的默认模板 """ from __future__ import annotations import os import shutil import uuid from pathlib import Path from typing import Optional from PyQt5.QtCore import Qt, QUrl, pyqtSignal from PyQt5.QtGui import QFont, QPixmap from...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/database_management.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.927751
#!/usr/bin/env python3 """ 数据库管理工具页面 提供数据库健康检查、修复、备份等功能 """ from PyQt5.QtCore import Qt, QTimer, pyqtSignal, QThread from PyQt5.QtGui import QFont from PyQt5.QtWidgets import (QWidget, QVBoxLayout, QHBoxLayout, QLabel, QPushButton, QTextEdit, QGroupBox, QProgressBar, ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/data_center_page.py
null
null
null
null
null
null
Python
2026-05-04T02:45:38.932733
#!/usr/bin/env python3 """ 数据中心页面:自动采集热点信息 - 支持多平台热榜(微博/百度/头条/B站) - 支持手动刷新 + 自动刷新 - 支持一键将热点词带回首页生成内容 """ from __future__ import annotations import time from typing import Dict, List, Optional from PyQt5.QtCore import Qt, QThread, QTimer, pyqtSignal, QUrl from PyQt5.QtGui import QFont from PyQt5.QtWidgets import ( ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/scheduled_publish_dialog.py
null
null
null
null
null
null
Python
2026-05-04T02:45:39.260713
#!/usr/bin/env python3 """ 定时发布弹窗 - 选择发布账号(用户) - 选择发布时间 - 支持“固定内容一次发布 / 跟随热点定期更新” """ from __future__ import annotations import os from typing import List, Optional from PyQt5.QtCore import Qt, QDateTime from PyQt5.QtGui import QFont from PyQt5.QtWidgets import ( QCheckBox, QComboBox, QDateTimeEdit, ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/home.py
null
null
null
null
null
null
Python
2026-05-04T02:45:39.297151
import shutil import time from PyQt5.QtCore import Qt, QUrl from PyQt5.QtGui import QColor, QPixmap, QDesktopServices from PyQt5.QtWidgets import (QFrame, QHBoxLayout, QLabel, QLineEdit, QPushButton, QTextEdit, QVBoxLayout, QWidget, QMessageBox, QComboBox, QFileDialog, QInputDialog) impor...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/setting.py
null
null
null
null
null
null
Python
2026-05-04T02:45:39.310446
from PyQt5.QtWidgets import QLabel, QVBoxLayout, QWidget from src.config.constants import VERSION from src.core.ui.qt_font import get_ui_text_font_family_css class SettingsPage(QWidget): """设置页面类""" def __init__(self, parent=None): super().__init__(parent) self.parent = parent ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/simple_backend_config.py
null
null
null
null
null
null
Python
2026-05-04T02:45:39.367380
#!/usr/bin/env python3 """ 简化的后台配置页面 解决按钮点击问题 """ import json import os from pathlib import Path from datetime import datetime from PyQt5.QtCore import Qt, QUrl, pyqtSignal from PyQt5.QtGui import QFont, QDesktopServices, QPixmap from PyQt5.QtWidgets import (QWidget, QVBoxLayout, QHBoxLayout, QLabel, ...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/template_manager.py
null
null
null
null
null
null
Python
2026-05-04T02:45:39.374252
#!/usr/bin/env python3 """ 模板管理器 负责加载和管理所有封面模板 """ import os import json from typing import Dict, List, Optional class TemplateManager: """模板管理器""" def __init__(self): self.templates = {} self.categories = {} self.load_templates() def load_templates(self...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/tools.py
null
null
null
null
null
null
Python
2026-05-04T02:45:39.403257
import base64 import os import asyncio from concurrent.futures import ThreadPoolExecutor, as_completed import requests from PyQt5.QtWidgets import (QFrame, QHBoxLayout, QLabel, QPushButton, QScrollArea, QTextEdit, QVBoxLayout, QWidget, QScrollArea, QGridLayou...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/pages/user_management_page.py
null
null
null
null
null
null
Python
2026-05-04T02:45:39.782026
#!/usr/bin/env python3 """ 用户管理页面 提供多账户创建/切换/编辑/删除 """ from PyQt5.QtCore import Qt from PyQt5.QtGui import QFont from PyQt5.QtWidgets import ( QWidget, QVBoxLayout, QHBoxLayout, QLabel, QPushButton, QTableWidget, QTableWidgetItem, QDialog, QLineEdit, QMessageBox, ) from src.cor...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/processor/content_backup.py
null
null
null
null
null
null
Python
2026-05-04T02:45:39.782795
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ 备用内容生成器 - 当主API不可用时的备选方案 """ import json import random import re import time import os import uuid from PyQt5.QtCore import QThread, pyqtSignal from src.core.services.system_image_template_service import system_image_template_service class BackupContentGenerat...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/processor/content.py
null
null
null
null
null
null
Python
2026-05-04T02:45:39.783575
import json import re import time import os import uuid from PyQt5.QtCore import QThread, pyqtSignal # 导入备用生成器 from .content_backup import BackupContentGenerator from src.config.config import Config from src.core.services.llm_service import llm_service, LLMServiceError from src.core.services.system_image_template_serv...
BetaStreetOmnis/xhs_ai_publisher
https://github.com/BetaStreetOmnis/xhs_ai_publisher
null
null
null
null
1,948
null
null
apache-2.0
null
null
null
null
null
null
null
src/core/processor/chrome_session_import.py
null
null
null
null
null
null
Python
2026-05-04T02:45:39.784176
from __future__ import annotations import json import os import shutil import subprocess import sys import tempfile import time import traceback from datetime import datetime from typing import Dict, Optional, Tuple from PyQt5.QtCore import QThread, pyqtSignal from playwright.sync_api import sync_playwright from src...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/custom_sentence_segmenter.py
null
null
null
null
null
null
Python
2026-05-04T02:45:43.879124
from typing import List import pysbd from spacy.tokens import Doc from spacy.language import Language from pysbd.utils import TextSpan from scispacy.consts import ABBREVIATIONS @Language.component("pysbd_sentencizer") def pysbd_sentencizer(doc: Doc) -> Doc: """Adds sentence boundaries to a Doc. Intended to...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
evaluation/evaluate_linker.py
null
null
null
null
null
null
Python
2026-05-04T02:45:43.940495
import spacy from scispacy.linking import EntityLinker from scispacy.data_util import read_full_med_mentions import os from tqdm import tqdm EVALUATION_FOLDER_PATH = os.path.dirname(os.path.abspath(__file__)) def main(): nlp = spacy.load("en_core_sci_sm") nlp.add_pipe( "scispacy_linker", config={"res...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/consts.py
null
null
null
null
null
null
Python
2026-05-04T02:45:43.960729
from typing import List ABBREVIATIONS: List[str] = [ "sec.", "secs.", "Sec.", "Secs.", "fig.", "figs.", "Fig.", "Figs.", "eq.", "eqs.", "Eq.", "Eqs.", "no.", "nos.", "No.", "Nos.", "al.", "gen.", "sp.", "nov.", ]
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/base_project_code.py
null
null
null
null
null
null
Python
2026-05-04T02:45:43.962198
from typing import Optional, Callable, Iterable, Iterator from pathlib import Path import random import itertools import spacy import warnings from spacy.training import Corpus, Example from spacy.language import Language from scispacy.custom_tokenizer import combined_rule_tokenizer from scispacy.data_util...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/candidate_generation.py
null
null
null
null
null
null
Python
2026-05-04T02:45:43.977577
from typing import Optional, List, Dict, Tuple, NamedTuple, Type, Union import json import datetime import os.path from collections import defaultdict from pathlib import Path import scipy import numpy import joblib from sklearn.feature_extraction.text import TfidfVectorizer import nmslib from nmslib.dist import Float...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/abbreviation.py
null
null
null
null
null
null
Python
2026-05-04T02:45:43.978884
from typing import Tuple, List, Optional, Set, Dict from collections import defaultdict from spacy.tokens import Span, Doc from spacy.matcher import Matcher from spacy.language import Language def find_abbreviation( long_form_candidate: Span, short_form_candidate: Span ) -> Tuple[Span, Optional[Span]]: """ ...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/custom_tokenizer.py
null
null
null
null
null
null
Python
2026-05-04T02:45:43.994109
from typing import List from spacy.lang import char_classes from spacy.symbols import ORTH from spacy.tokenizer import Tokenizer from spacy.util import compile_prefix_regex, compile_infix_regex, compile_suffix_regex from spacy.language import Language from scispacy.consts import ABBREVIATIONS def remove_new_lines(t...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
evaluation/sentence_splitting_evaluation.py
null
null
null
null
null
null
Python
2026-05-04T02:45:44.003582
import argparse import os import sys import json import spacy sys.path.insert(0, os.path.dirname(os.path.abspath(os.path.join(__file__, os.pardir)))) from scispacy.custom_sentence_segmenter import combined_rule_sentence_segmenter from scispacy.custom_tokenizer import remove_new_lines, combined_rule_tokenizer def eva...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/data_util.py
null
null
null
null
null
null
Python
2026-05-04T02:45:44.114177
from typing import Optional, NamedTuple, List, Iterator, Dict, Tuple import tarfile import atexit import os import shutil import tempfile from scispacy.file_cache import cached_path class MedMentionEntity(NamedTuple): start: int end: int mention_text: str mention_type: str umls_id: str class Me...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/file_cache.py
null
null
null
null
null
null
Python
2026-05-04T02:45:44.443544
""" Utilities for working with the local dataset cache. """ import os import shutil import tempfile import json from urllib.parse import urlparse from pathlib import Path from typing import Optional, Tuple, Union, IO from hashlib import sha256 import requests from tqdm import tqdm CACHE_ROOT = Path(os.getenv("SCISPA...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/hyponym_detector.py
null
null
null
null
null
null
Python
2026-05-04T02:45:44.952345
from spacy.matcher import Matcher from spacy.tokens import Token, Doc from spacy.language import Language from scispacy.hearst_patterns import BASE_PATTERNS, EXTENDED_PATTERNS @Language.factory("hyponym_detector") class HyponymDetector: """ A spaCy pipe for detecting hyponyms using Hearst patterns. This ...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/per_class_scorer.py
null
null
null
null
null
null
Python
2026-05-04T02:45:44.953025
from typing import Dict, List, Tuple, Set from collections import defaultdict import copy class PerClassScorer: def __init__(self): # These will hold per label span counts. self._true_positives: Dict[str, int] = defaultdict(int) self._false_positives: Dict[str, int] = defaultdict(int) ...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/linking_utils.py
null
null
null
null
null
null
Python
2026-05-04T02:45:44.954897
""" This submodule contains a data structure for storing lexical indexes over various biomedical vocabularies. There are several built-in vocabularies, which can be imported and instantiated like in: .. code-block:: python from scispacy.linking_utils import UmlsKnowledgeBase kb = UmlsKnowledgeBase() In gen...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/linking.py
null
null
null
null
null
null
Python
2026-05-04T02:45:44.956198
from typing import Any, Optional, Dict from spacy.tokens import Doc from spacy.tokens import Span from spacy.language import Language from typing_extensions import Self from scispacy.candidate_generation import CandidateGenerator, create_tfidf_ann_index from scispacy.linking_utils import KnowledgeBase @Language.fac...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/hearst_patterns.py
null
null
null
null
null
null
Python
2026-05-04T02:45:44.957184
from typing import List, Dict, Any """ BSD 3-Clause License Copyright (c) 2020, Fourthought All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copy...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/umls_linking.py
null
null
null
null
null
null
Python
2026-05-04T02:45:47.073430
# Kept for backward compatability. from scispacy.linking import EntityLinker as UmlsEntityLinker # noqa: F401
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/umls_utils.py
null
null
null
null
null
null
Python
2026-05-04T02:45:47.074369
from typing import Optional, List, Dict # TODO(Mark): Remove in scispacy v1.0, for backward compatability only. from scispacy.linking_utils import Entity as UmlsEntity, UmlsKnowledgeBase # noqa # preferred definition sources (from S2) DEF_SOURCES_PREFERRED = {"NCI_BRIDG", "NCI_NCI-GLOSS", "NCI", "GO", "MSH", "NCI_FD...
allenai/scispacy
https://github.com/allenai/scispacy
null
null
null
null
1,947
null
null
apache-2.0
null
null
null
null
null
null
null
scispacy/umls_semantic_type_tree.py
null
null
null
null
null
null
Python
2026-05-04T02:45:47.230996
from typing import NamedTuple, List, Dict, Deque, Any, Optional from collections import deque from scispacy.file_cache import cached_path class SemanticTypeNode(NamedTuple): type_id: str full_name: str children: List[Any] # Mypy does not support nested types yet :( level: int class UmlsSemanticTyp...