{"id":20760919,"url":"https://github.com/ikkkp/ocean_transformer_process","last_synced_at":"2026-06-07T14:31:22.430Z","repository":{"id":209174967,"uuid":"723335881","full_name":"ikkkp/Ocean_transformer_process","owner":"ikkkp","description":null,"archived":false,"fork":false,"pushed_at":"2023-11-25T16:28:26.000Z","size":25,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-20T00:15:12.269Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ikkkp.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-11-25T10:46:40.000Z","updated_at":"2023-11-25T10:46:48.000Z","dependencies_parsed_at":"2023-11-25T16:25:34.138Z","dependency_job_id":"e059eb16-d02b-4fd7-8bd8-db9e12eac7bd","html_url":"https://github.com/ikkkp/Ocean_transformer_process","commit_stats":null,"previous_names":["ikkkp/ocean_transformer_process"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ikkkp/Ocean_transformer_process","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ikkkp%2FOcean_transformer_process","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ikkkp%2FOcean_transformer_process/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ikkkp%2FOcean_transformer_process/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ikkkp%2FOcean_transformer_process/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ikkkp","download_url":"https://codeload.github.com/ikkkp/Ocean_transformer_process/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ikkkp%2FOcean_transformer_process/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34025803,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-07T02:00:07.652Z","response_time":124,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-17T10:16:33.907Z","updated_at":"2026-06-07T14:31:22.411Z","avatar_url":"https://github.com/ikkkp.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Ocean Toolkit for Document Processing\n\n## Introduction\n\nThe Ocean Toolkit is a powerful tool designed for processing PDF documents. It leverages the Xenova/nougat-base model from Transformers to generate summaries of PDF documents based on a specified token length. Additionally, it supports sentence segmentation for both Chinese and English text and efficiently converts summary text data into high-quality vector data. The toolkit seamlessly integrates with the Qdrant vector database, facilitating vector storage and retrieval, ultimately contributing to the construction of a knowledge graph.\n\n## Key Features\n\n- PDF Document Summarization: Utilize the Xenova/nougat-base model to generate document summaries with a specified token length.\n- Sentence Segmentation: Support sentence segmentation for both Chinese and English text to enhance text processing accuracy.\n- Vector Data Generation: Quickly generate high-quality vector data based on summary text data.\n- Vector Database Operations: Leverage the Qdrant vector database for efficient vector storage and retrieval, enabling fast searches and knowledge graph construction.\n\n## Installation\n\n```bash\npip install ocean-toolkit\n```\n\n## Usage Example\n\n```python\nfrom ocean_toolkit import OceanToolkit\n\n# Initialize the Ocean Toolkit\nocean_toolkit = OceanToolkit()\n\n# Read a PDF document\npdf_path = \"example.pdf\"\npdf_content = ocean_toolkit.read_pdf(pdf_path)\n\n# Generate a document summary\nsummary = ocean_toolkit.generate_summary(pdf_content, max_token_length=200)\n\n# Split the text into sentences\nsentences = ocean_toolkit.split_sentences(summary)\n\n# Generate vectors from the text\nvectors = ocean_toolkit.generate_vectors(sentences)\n\n# Save vectors to the Qdrant database\nocean_toolkit.save_to_qdrant(vectors, document_ids=range(len(sentences)))\n\n# Search vectors in the Qdrant database\nquery_vector = ocean_toolkit.generate_vectors([\"query sentence\"])[0]\nresult = ocean_toolkit.search_in_qdrant(query_vector)\n```\n\n## Contribution\n\nContributions, questions, and improvement suggestions are welcome. Please refer to the [Contribution Guidelines](CONTRIBUTING.md) for more information.\n\n## License\n\nThis toolkit is released under the [MIT License](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fikkkp%2Focean_transformer_process","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fikkkp%2Focean_transformer_process","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fikkkp%2Focean_transformer_process/lists"}