copilot-session-tools 0.1.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- copilot_session_tools/__init__.py +72 -0
- copilot_session_tools/cli.py +993 -0
- copilot_session_tools/database.py +1848 -0
- copilot_session_tools/html_exporter.py +270 -0
- copilot_session_tools/markdown_exporter.py +426 -0
- copilot_session_tools/py.typed +0 -0
- copilot_session_tools/scanner/__init__.py +73 -0
- copilot_session_tools/scanner/cli.py +606 -0
- copilot_session_tools/scanner/content.py +313 -0
- copilot_session_tools/scanner/diff.py +297 -0
- copilot_session_tools/scanner/discovery.py +365 -0
- copilot_session_tools/scanner/git.py +114 -0
- copilot_session_tools/scanner/models.py +122 -0
- copilot_session_tools/scanner/vscode.py +693 -0
- copilot_session_tools/web/__init__.py +107 -0
- copilot_session_tools/web/templates/error.html +61 -0
- copilot_session_tools/web/templates/index.html +1072 -0
- copilot_session_tools/web/templates/session.html +1592 -0
- copilot_session_tools/web/webapp.py +610 -0
- copilot_session_tools-0.1.1.dist-info/METADATA +375 -0
- copilot_session_tools-0.1.1.dist-info/RECORD +24 -0
- copilot_session_tools-0.1.1.dist-info/WHEEL +4 -0
- copilot_session_tools-0.1.1.dist-info/entry_points.txt +3 -0
- copilot_session_tools-0.1.1.dist-info/licenses/LICENSE +21 -0
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
"""Copilot Session Tools - Common utilities.
|
|
2
|
+
|
|
3
|
+
This module provides shared functionality for working with VS Code Copilot chat history:
|
|
4
|
+
- Database: SQLite storage with FTS5 full-text search
|
|
5
|
+
- Scanner: Find and parse chat session files from VS Code workspace storage
|
|
6
|
+
- Markdown Exporter: Convert chat sessions to markdown format
|
|
7
|
+
|
|
8
|
+
This project borrows patterns from several open-source projects:
|
|
9
|
+
- simonw/claude-code-transcripts: HTML transcript generation approach
|
|
10
|
+
- Arbuzov/copilot-chat-history: VS Code Copilot chat session data format
|
|
11
|
+
- jazzyalex/agent-sessions: Multi-agent session concept, SQLite indexing
|
|
12
|
+
- tad-hq/universal-session-viewer: FTS5 full-text search design
|
|
13
|
+
"""
|
|
14
|
+
|
|
15
|
+
__version__ = "0.1.1"
|
|
16
|
+
|
|
17
|
+
from .database import Database, ParsedQuery, parse_search_query
|
|
18
|
+
from .html_exporter import (
|
|
19
|
+
export_session_to_html_file,
|
|
20
|
+
generate_session_html_filename,
|
|
21
|
+
session_to_html,
|
|
22
|
+
)
|
|
23
|
+
from .markdown_exporter import (
|
|
24
|
+
export_session_to_file,
|
|
25
|
+
generate_session_filename,
|
|
26
|
+
message_to_markdown,
|
|
27
|
+
session_to_markdown,
|
|
28
|
+
)
|
|
29
|
+
from .scanner import (
|
|
30
|
+
ChatMessage,
|
|
31
|
+
ChatSession,
|
|
32
|
+
CommandRun,
|
|
33
|
+
ContentBlock,
|
|
34
|
+
FileChange,
|
|
35
|
+
ToolInvocation,
|
|
36
|
+
detect_repository_url,
|
|
37
|
+
find_copilot_chat_dirs,
|
|
38
|
+
get_cli_storage_paths,
|
|
39
|
+
get_vscode_storage_paths,
|
|
40
|
+
scan_chat_sessions,
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
__all__ = [
|
|
44
|
+
# Scanner - Data models
|
|
45
|
+
"ChatMessage",
|
|
46
|
+
"ChatSession",
|
|
47
|
+
"CommandRun",
|
|
48
|
+
"ContentBlock",
|
|
49
|
+
# Database
|
|
50
|
+
"Database",
|
|
51
|
+
"FileChange",
|
|
52
|
+
"ParsedQuery",
|
|
53
|
+
"ToolInvocation",
|
|
54
|
+
# Package
|
|
55
|
+
"__version__",
|
|
56
|
+
# Scanner - Discovery & parsing
|
|
57
|
+
"detect_repository_url",
|
|
58
|
+
# Markdown Exporter
|
|
59
|
+
"export_session_to_file",
|
|
60
|
+
# HTML Exporter
|
|
61
|
+
"export_session_to_html_file",
|
|
62
|
+
"find_copilot_chat_dirs",
|
|
63
|
+
"generate_session_filename",
|
|
64
|
+
"generate_session_html_filename",
|
|
65
|
+
"get_cli_storage_paths",
|
|
66
|
+
"get_vscode_storage_paths",
|
|
67
|
+
"message_to_markdown",
|
|
68
|
+
"parse_search_query",
|
|
69
|
+
"scan_chat_sessions",
|
|
70
|
+
"session_to_html",
|
|
71
|
+
"session_to_markdown",
|
|
72
|
+
]
|