forked from balisujohn/localwriter
-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy path__init__.py
More file actions
42 lines (34 loc) · 1.2 KB
/
Copy path__init__.py
File metadata and controls
42 lines (34 loc) · 1.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# Copyright (c) David Berlioz
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at https://mozilla.org/MPL/2.0/.
"""Common tools for all document types."""
from plugin.framework.module_base import ModuleBase
class CommonModule(ModuleBase):
"""Provides generic document tools (info, save, export)."""
def initialize(self, services):
self.services = services
from . import (
diagnostics,
document_research_grep_tool,
document_research_specialized,
document_research_tools,
find_tools_tool,
print_doc,
undo,
)
from plugin.embeddings import (
document_research_fts_tool,
)
discovery_modules = (
diagnostics,
document_research_tools,
document_research_grep_tool,
document_research_fts_tool,
document_research_specialized,
find_tools_tool,
print_doc,
undo,
)
for module in discovery_modules:
services.tools.auto_discover(module)