Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
365 commits
Select commit Hold shift + click to select a range
b97b32e
SimpleChatTC:Cleanup:ChatProps: iRecentUserMsgCnt
hanishkvc Oct 21, 2025
2894e4d
SimpleChatTC:Cleanup:ChatProps: bCompletionFreshChatAlways
hanishkvc Oct 21, 2025
e29db58
SimpleChatTC:Cleanup:ChatProps: bCompletionInsertStandardRolePrefix
hanishkvc Oct 21, 2025
f52b95e
SimpleChatTC:Cleanup:ChatProps: bTrimGarbage
hanishkvc Oct 21, 2025
94a8157
SimpleChatTC:Cleanup:ChatProps: apiEP
hanishkvc Oct 22, 2025
ee4b423
SimpleChatTC:Tools: Show available tool names
hanishkvc Oct 22, 2025
7b9fdf7
SimpleChatTC:SimpleProxy:Allow for loading json based config file
hanishkvc Oct 23, 2025
d4350d1
SimpleChatTC:SimpleProxy: Update doc following python convention
hanishkvc Oct 23, 2025
d486e2c
SimpleChatTC:SimpleProxy: AllowedDomains based filtering
hanishkvc Oct 23, 2025
004b31d
SimpleChatTC:SimpleProxy: Cleanup domain filtering and general
hanishkvc Oct 23, 2025
83cfcb9
SimpleChatTC:SimpleProxy: Include a sample config file
hanishkvc Oct 23, 2025
a43668c
SimpleChatTC: Update readme a bit
hanishkvc Oct 23, 2025
4814217
SimpleChatTC:SimpleProxy: Some debug prints which give info
hanishkvc Oct 23, 2025
a40a845
SimpleChatTC:SimpleProxy:Try mimic real client using got req info
hanishkvc Oct 23, 2025
8772646
SimpleChatTC:SimpleProxy:Cleanup a bit
hanishkvc Oct 23, 2025
af0b333
SimpleChatTC:SimpleProxy: mimicing got req helps wrt duckduckgo
hanishkvc Oct 23, 2025
1fa3cb0
SimpleChatTC:ToolCall response relaxed handling
hanishkvc Oct 23, 2025
ddc2e9d
SimpleChatTC:SimpleProxy: Update readme wrt mimicing client req
hanishkvc Oct 23, 2025
1ce5e32
SimpleChatTC:ToolResponse: Use browser dom for xml/html safe
hanishkvc Oct 23, 2025
69c6a7d
SimpleChatTC:SimpleProxy: debug dumps to identify funny bing
hanishkvc Oct 23, 2025
22ccae3
SimpleChatTC:SimpleProxy:Cleanup
hanishkvc Oct 23, 2025
1e580d7
SimpleChatTC:Auto tool calling control to end user
hanishkvc Oct 23, 2025
d865b04
SimpleChatTC:AutoToolCalls: Track and clear related timers
hanishkvc Oct 24, 2025
bbf6e4c
SimpleChatTC: Cleanup whitespaces
hanishkvc Oct 24, 2025
f9c6273
SimpleChatTC:Cleanup whitespace - github editorconfig checker
hanishkvc Oct 24, 2025
95f75e3
SimpleChatTC:Update and cleanup the readme a bit
hanishkvc Oct 26, 2025
af38fa4
SimpleChatTC:Duplicate tooljs.mjs to toolweb.mjs
hanishkvc Oct 26, 2025
64ccfd0
SimpleChatTC:ToolCalling:Seprat out JSWebWorker and ProxyBasedWeb
hanishkvc Oct 26, 2025
5354af3
SimpleChatTC:ToolCall:SearchWebText using UrlText
hanishkvc Oct 26, 2025
6a44daf
SimpleChatTC:ToolCallWeby: Cleanup the toolweb module flow
hanishkvc Oct 26, 2025
d97f2c0
SimpleChatTC:WebSearchPlus: Update readme, Wikipedia in allowed
hanishkvc Oct 26, 2025
e15f517
SimpleChatTC:ToolCallResponseTimeout: Allow end user to control
hanishkvc Oct 26, 2025
d9b3585
SimpleChatTC:SimpleProxy:LoadConfig ProcessArgs cleanup - initial
hanishkvc Oct 27, 2025
ce71a2b
SimpleChatTC:SimpleProxy: Prg Parameters handling cleanup - next
hanishkvc Oct 27, 2025
c0b4214
SimpleChatTC:SimpleProxy:BearerInsecure a needed config
hanishkvc Oct 27, 2025
00c3dc2
SimpleChatTC:SimpleProxy: Check for bearer authorization
hanishkvc Oct 27, 2025
3cbc99b
SimpleChatTC:tools.proxyUrl: rename to just proxyUrl
hanishkvc Oct 27, 2025
1452c96
SimpleChatTC:SimpleProxy:ClientUI: Send Authorization bearer
hanishkvc Oct 27, 2025
f77b2e4
SimpleChatTC:SimpleProxy: once in a bluemoon transformed bearer
hanishkvc Oct 27, 2025
4db7b46
SimpleChatTC:ToolTemp and ChatShow
hanishkvc Oct 27, 2025
1c5fd6e
SimpleChatTC:ToolCallErrPath:ToolTemp and MultiChatUIChatShow
hanishkvc Oct 27, 2025
c0d7d17
SimpleChatTC:ToolTemp: Ensure add removes non promoted ToolTemp
hanishkvc Oct 27, 2025
f20ac86
SimpleChatTC:ChatSessionID through the tool call cycle
hanishkvc Oct 27, 2025
800d3ae
SimpleChatTC:ChatSessionID: Get all handlers to account for chatid
hanishkvc Oct 27, 2025
48c824f
SimpleChatTC:Reasoning: Initial Go
hanishkvc Oct 27, 2025
4ed20ce
SimpleChatTC:Reasoning: Cleanup the initial go
hanishkvc Oct 28, 2025
b4a72f0
SimpleChatTC:SimpleProxy: Include some news sites in allowed domains
hanishkvc Oct 28, 2025
95787f9
SimpleChatTC:Show: Cleanup
hanishkvc Oct 28, 2025
4d9b9f2
SimpleChatTC:MultiChatUI.ChatShow: Mov SimpleChat.Show in -initial
hanishkvc Oct 28, 2025
b6660ed
SimpleChatTC:MultiChatUI:ChatShow cleanup of Initial skeleton
hanishkvc Oct 28, 2025
a9a3ffc
SimpleChatTC:Reasoning+: Update readme wrt reasoning, flow cleanup
hanishkvc Oct 28, 2025
2e5d7d0
SimpleChatTC:Cleanup: tool resp xml, some allowed domains
hanishkvc Oct 28, 2025
f8bce3e
SimpleChatTC:Cleanup:Move showing message into ShowMessage
hanishkvc Oct 29, 2025
af00424
SimpleChatTC:ShowMessage: containers, role, contents
hanishkvc Oct 29, 2025
e173a6d
SimpleChatTC:CSS: Instead of hardcoded btn minwidth use padding
hanishkvc Oct 29, 2025
7e9df26
SimpleChatTC:ShowMessage: Seperate out the content parts
hanishkvc Oct 29, 2025
efb6324
SimpleChatTC:ShowMessage:Show any number of toolcalls
hanishkvc Oct 29, 2025
fe89cb5
SimpleChatTC:UICleanup: WordBreaks, Print avoid side vertical
hanishkvc Oct 29, 2025
e71675a
SimpleChatTC:UICleanup:ShowMessage: Update readme
hanishkvc Oct 29, 2025
52f55f4
SimpleChatTC:DataStore: Initial skeleton of a Db WebWorker
hanishkvc Oct 29, 2025
921f58f
SimpleChatTC:DataStore: Duplicate tooljs to tooldb initial skel
hanishkvc Oct 29, 2025
20a3893
SimpleChatTC:DataStore: Remaining plumbing to try this
hanishkvc Oct 29, 2025
27a9f57
SimpleChatTC:DataStore:FuncCallArgs: Any type not supported
hanishkvc Oct 29, 2025
edaeb75
SimpleChatTC:DataStore:Eagerness to Wrong JSON conversions
hanishkvc Oct 29, 2025
5fb9478
SimpleChatTC:DataStore: Dont ignore the error paths
hanishkvc Oct 29, 2025
0f2e0a2
SimpleChatTC:DataStore:Put, stringify undefined, readme
hanishkvc Oct 29, 2025
308eefc
SimpleChatTC:DataStore: Delete a record - the db web worker side
hanishkvc Oct 30, 2025
6d26b39
SimpleChatTC:DataStore:Delete a record - the plumbing side
hanishkvc Oct 30, 2025
32b3c3d
SimpleChatTC:DataStore:list - web worker side logic
hanishkvc Oct 30, 2025
66804ea
SimpleChatTC:DataStore:List keys - the plumbing
hanishkvc Oct 30, 2025
4292eab
SimpleChatTC:DataStore:Cleanup:Msg, duplicate on routing side
hanishkvc Oct 30, 2025
5a60bdd
SimpleChatTC:DataStore: update readme
hanishkvc Oct 30, 2025
bb4f049
SimpleChatTC:ToolsWorker: Update note to flow with chat session id
hanishkvc Nov 1, 2025
d228195
SimpleChatTC:Seperate out actual nw handshake - initial go
hanishkvc Nov 1, 2025
ce0e77a
SimpleChatTC:Move chat server handshake to SimpleChat
hanishkvc Nov 1, 2025
f1fdc1c
SimpleChatTC:Raise Error on Ai Chat server handshake NotOk resp
hanishkvc Nov 1, 2025
a324843
SimpleChatTC: Update readme
hanishkvc Nov 1, 2025
10c7263
SimpleChatTC:SimpleProxy: Enable allowing or not requested feature
hanishkvc Nov 1, 2025
16499db
SimpleChatTC:SimpleProxy:Pdf2Text:Initial plumbing
hanishkvc Nov 1, 2025
94f37c2
SimpleChatTC:SimpleProxy:Pdf2Text: Move handling url to its own
hanishkvc Nov 1, 2025
64439c8
SimpleChatTC:SimpleProxy:Pdf2Text: Initial go
hanishkvc Nov 1, 2025
4a071d7
SimpleChatTC:SimpleProxy:Pdf2Text: js side initial plumbing
hanishkvc Nov 1, 2025
cfee209
SimpleChatTC:Pdf2Text: cleanup initial go
hanishkvc Nov 1, 2025
361d6e1
SimpleChatTC:ResultMaxDataLength, Desc
hanishkvc Nov 1, 2025
7c4d488
SimpleChatTC:Pdf2Text: Refine desc and MaxResultDataLength
hanishkvc Nov 1, 2025
40829c1
SimpleChatTC:Pdf2Text and otherwise readme update
hanishkvc Nov 1, 2025
dfb154e
SimpleChatTC:SimpleProxyHS: make helper work with any num of args
hanishkvc Nov 1, 2025
9305799
SimpleChatTC:TC Result truncating only if needed
hanishkvc Nov 1, 2025
136dd58
SimpleChatTC:Pdf2Text: Make it work with a subset of pages
hanishkvc Nov 1, 2025
bd85df9
SimpleChatTC:Fixup auto toolcall wrt newer ChatShow flow
hanishkvc Nov 1, 2025
8650a96
SimpleChatTC:Update notes
hanishkvc Nov 2, 2025
6f52e89
SimpleChatTC:SimpleProxy:UrlValidator module initial skeleton
hanishkvc Nov 2, 2025
21845eb
SimpleChatTC:SimpleProxy:UrlValidator initial go
hanishkvc Nov 2, 2025
6c50b58
SimpleChatTC:SimpleProxy: Use urlvalidator
hanishkvc Nov 2, 2025
ac71680
SimpleChatTC:SimpleProxy: AuthAndRun hlpr for paths that check auth
hanishkvc Nov 2, 2025
6e1d080
SimpleChatTC:SimpleProxy:Move pdf logic into its own module
hanishkvc Nov 2, 2025
0d06d22
SimpleChatTC:SimpleProxy: Move web requests to its own module
hanishkvc Nov 2, 2025
772d267
SimpleChatTC:SimpleProxy: Avoid circular deps wrt Type Checking
hanishkvc Nov 2, 2025
50fa20b
SimpleChatTC:SimpleProxy:Pdf2Text cleanup page number handling
hanishkvc Nov 2, 2025
ed391ff
SimpleChatTC:SimpleProxy: getting local / web file module ++
hanishkvc Nov 2, 2025
9a8ff55
SimpleChatTC:SimpleProxy:Pdf2Text update /cleanup readme
hanishkvc Nov 2, 2025
bf89061
SimpleChatTC:SimpleProxy:Switch web flow to use file helpers
hanishkvc Nov 2, 2025
0ec8fbb
SimpleChatTC:SimpleProxy:Add generic arxiv.org entry to allowed
hanishkvc Nov 2, 2025
fc8f1bb
SimpleChatTC: Cleanup - remove older now unused show chat logic
hanishkvc Nov 2, 2025
714c13a
SimpleChatTC:Cleanup Usage Note and its presentation a bit
hanishkvc Nov 2, 2025
5ea269e
SimpleChatTC:Cleanup:UsageNote, Initial SettingsInfo shown
hanishkvc Nov 3, 2025
1cb0dab
SimpleChatTC:PdfText:Cleanup rename to follow a common convention
hanishkvc Nov 3, 2025
228091c
SimpleChatTC: ToolCalling enabled, Sliding window adjust
hanishkvc Nov 3, 2025
2097c09
SimpleChatTC:SimpleProxy: Validate deps wrt enabled service paths
hanishkvc Nov 3, 2025
45a8c35
SimpleChatTC:SettingsDefault:Enable cache prompt api option
hanishkvc Nov 3, 2025
c30a287
SimpleChatTC:WebTools And Search - headers and search drops - js
hanishkvc Nov 3, 2025
14aa437
SimpleChatTC:WebTools: urltext-tag-drops python side - skel
hanishkvc Nov 3, 2025
eee8830
SimpleChatTC:WebTools:UrlText:HtmlParser: tag drops - refine
hanishkvc Nov 3, 2025
619a997
SimpleChatTC:Cleanup in general
hanishkvc Nov 3, 2025
1efffa0
SimpleChatTC:Cleanup: General T2
hanishkvc Nov 4, 2025
84a8372
SimpleChatTC:UI:ClearChat, Unicode icons for Clear, settings
hanishkvc Nov 4, 2025
ba68df9
SimpleChatTC:FetchPdfAsText: Renamed function call
hanishkvc Nov 5, 2025
44dfe0c
SimpleChatTC:System Date and Time
hanishkvc Nov 5, 2025
37ddd3b
SimpleChatTC:Cleanup:Make main chat related classes importable
hanishkvc Nov 5, 2025
389abf9
SimpleChatTC:Cleanup:MeInTools: update tools, toolweb
hanishkvc Nov 5, 2025
295dfce
SimpleChatTC:MeInTools: WebWorkers in Me
hanishkvc Nov 5, 2025
9d7042f
SimpleChatTC:Rather bring in Tools Class
hanishkvc Nov 5, 2025
11109f5
SimpleChatTC:ToolsManager: Instantiate in Me and Use
hanishkvc Nov 5, 2025
24ea71b
SimpleChatTC:ToolsManager: Cleanup inc delayed direct posting
hanishkvc Nov 5, 2025
f64d31a
SimpleChatTC:TrackToolCalls:helps ignor delayed response, if reqd
hanishkvc Nov 6, 2025
33370e6
SimpleChatTC:TCPending: Clear pending in unhappy paths
hanishkvc Nov 6, 2025
76fdefc
SimpleChatTC:IndexHTML:Fix a oversight with new module added
hanishkvc Nov 6, 2025
8ef056d
SimpleChatTC:SimpleProxy:XMLText: initial go
hanishkvc Nov 6, 2025
0f8768e
SimpleChatTC:XmlText: Add plumbing on web client ui ie js side
hanishkvc Nov 6, 2025
b14c583
SimpleChatTC:XmlText: Cleanup initial go
hanishkvc Nov 6, 2025
65e0d6f
SimpleChatTC:XMLFiltered: Retain xml tags with selective dropping
hanishkvc Nov 7, 2025
b780ab1
SimpleChatTC:XmlFiltered: Use re with heirarchy of tags to filter
hanishkvc Nov 7, 2025
06e8809
SimpleChatTC:ShowToolCall: Trap invalid args generated by GenAi
hanishkvc Nov 7, 2025
4f00434
SimpleChatTC:Rename fetch_web_url_text to fetch_html_text
hanishkvc Nov 7, 2025
9ee8656
SimpleChatTC:XmlFiltered: Avoid showing skipped tags as no content
hanishkvc Nov 7, 2025
3434760
SimpleChatTC:Get body also for Not Ok responses from ai server
hanishkvc Nov 7, 2025
067a1a4
SimpleChatTC:PdfText:Add initial skeleton for outline
hanishkvc Nov 7, 2025
e0274ad
SimpleChatTC:PdfText: Numbering T1 - Diff Scheme needed
hanishkvc Nov 7, 2025
1774876
SimpleChatTC:PdfText:Numbering T2 - Need diff scheme
hanishkvc Nov 7, 2025
9867417
SimpleChatTC:PdfText:Basic Outline and its Numbering done
hanishkvc Nov 7, 2025
e788854
SimpleChatTC:ChatMessage undefined driven
hanishkvc Nov 8, 2025
ef32675
SimpleChatTC:NSChatMessage class driven wrt ChatMessageEx
hanishkvc Nov 8, 2025
d1886e8
SimpleChatTC:NSChatMessage: Update SimpleChat to use same
hanishkvc Nov 8, 2025
02fd8a0
SimpleChatTC:NSChatMessage: MultiChatUI and beyond updated for same
hanishkvc Nov 8, 2025
e188093
SimpleChatTC:NSChatMessage with tool response/result fields
hanishkvc Nov 8, 2025
99f2b20
SimpleChatTC:NSChatMessage:ToolResponse show handling
hanishkvc Nov 8, 2025
ffb9f86
SimpleChatTC:NSChatMessage: Handle edits by user wrt tool response
hanishkvc Nov 8, 2025
7987a1f
SimpleChatTC:NSChatMessage:Tool role newFromOld and load fixup
hanishkvc Nov 8, 2025
4d0f02b
SimpleChatTC:NSChatMessage: fix up initial go
hanishkvc Nov 8, 2025
323c1d3
SimpleChatTC:NSChatMessage:ToolResult User Input Background color
hanishkvc Nov 8, 2025
16f439a
SimpleChatTC:Alert end user in case emtpy message to ai
hanishkvc Nov 9, 2025
2c95f92
SimpleChatTC:Vision: Prepare NSChatMessage for Text &| Image
hanishkvc Nov 9, 2025
7a8cbfe
SimpleChatTC:Vision: take care of image_url wrt newFrom & load
hanishkvc Nov 9, 2025
42ce8ca
SimpleChatTCRV:Vision: Create needed MixedContent b4 nw handshake
hanishkvc Nov 9, 2025
2acc27c
SimpleChatTCRV:Vision: Add file input to get hold of img file
hanishkvc Nov 9, 2025
bd6fed3
SimpleChatTCRV:Basic skeleton to load a dataUrl
hanishkvc Nov 10, 2025
3ada24a
SimpleChatTCRV:Submit: Remember to include image, if available
hanishkvc Nov 10, 2025
7765ceb
SimpleChatTCRV:Vision:Show images as part of the message
hanishkvc Nov 10, 2025
60faeb6
SimpleChatTCRV:Vision:Show user image selection in btn
hanishkvc Nov 10, 2025
092203f
SimpleChatTCRV:Vision:HandleUserSubmit: Ensure cleanup even early
hanishkvc Nov 10, 2025
7a64033
SimpleChatTCRV:Vision: DataUrl helpers
hanishkvc Nov 10, 2025
ef5e7c4
SimpleChatTCRV:HandleUserSubmit:details of internaly caught exc
hanishkvc Nov 10, 2025
919ff3f
SimpleChatTCRV:UI Cleanup: scrollOnlyIf, Tool HR, Msg Margin
hanishkvc Nov 11, 2025
9305e20
SimpleChatTCRV:UI Cleanup: DetailsNotDiv Current settings info
hanishkvc Nov 11, 2025
5d9a955
SimpleChatTCRV:UICleanup: ObjInfo dClassNames
hanishkvc Nov 11, 2025
5208e1b
SimpleChatTCRV:UICleanup: gradient wrt heading
hanishkvc Nov 11, 2025
512b819
SimpleChatTC:IDBHelper: Move core indexedDB helper as a module
hanishkvc Nov 11, 2025
dc63729
SimpleChatTCRV:iDB:Add Put/Get; SimpleChat Save/Load using iDB
hanishkvc Nov 11, 2025
c8d337c
SimpleChatTCRV:iDB:GetKeys: helps decide whether restore btn shown
hanishkvc Nov 11, 2025
14e4900
SimpleChatTCRV:InputFileDialog:AcceptList:Images:Jpeg and Png
hanishkvc Nov 11, 2025
9936caf
SimpleChatTCRV: Response handling try catch, update errors
hanishkvc Nov 12, 2025
c71ccc6
SimpleChatTCRV:Remember to reset the Input File type value
hanishkvc Nov 12, 2025
6f2f794
SimpleChatTCRV:ChatMessage: UniqId, Delete logic, edit popover ui
hanishkvc Nov 13, 2025
70fc473
SimpleChatTCRV:CMPopOver: show within chatmessage, del logic
hanishkvc Nov 13, 2025
716a795
SimpleChatTCRV:CMPopOver:Relative positioning - P1
hanishkvc Nov 13, 2025
818e289
SimpleChatTCRV:CMPopOver:Relative positioning - P2
hanishkvc Nov 13, 2025
8f2dfc7
SimpleChatTCRV:ChatMessage:Copy using PopOver menu & navigator
hanishkvc Nov 13, 2025
722e5d3
SimpleChatTCRV:Cleanup:Delete keeps view around adjacent messages
hanishkvc Nov 14, 2025
6e5ea98
SimpleChatTCRV: Update readme a bit, need to cleanup later
hanishkvc Nov 14, 2025
280f6f6
SimpleChatTCRV:SimpleProxy:DumpHeaders
hanishkvc Nov 14, 2025
705f7e9
SimpleChatTCRV:CleanUp: Refresh chat ui, if user empty submits
hanishkvc Nov 14, 2025
4b0f392
SimpleChatTCRV:Cleanup: Efficient ChatMessage Ui Delete
hanishkvc Nov 14, 2025
317fc3e
SimpleChatTCRV:Cleanup:Delete and Chat UI suitable update
hanishkvc Nov 14, 2025
8218781
SimpleChatTCRV:MCUI:ChatMsgAddShow, Use4 toolresp nonhappy paths
hanishkvc Nov 14, 2025
cbd870d
SimpleChatTCRV:MCUI:CMAddShow:tool response happy path
hanishkvc Nov 15, 2025
1d91179
SimpleChatTCRV:CMOptimisedShow: User respones
hanishkvc Nov 15, 2025
2175b28
SimpleChatTCRV:Cleanup:Distinguish btw uiremove & del_uiupdate
hanishkvc Nov 15, 2025
4d62e2e
SimpleChatTCRV:CMUI: remove live element, uidelete all matching
hanishkvc Nov 15, 2025
e518bca
SimpleChatTCRV:CMUI:Scroll into view in optimized ui flows
hanishkvc Nov 15, 2025
854ab6c
SimpleChatTCRV:UI Flow cleanup plus
hanishkvc Nov 16, 2025
0d56401
SimpleChatTCRV:UICleanupPlus: Fix oversights with initial go
hanishkvc Nov 16, 2025
62bb60a
SimpleChatTCRV:UICleanup: Use chat_uirefresh not chat_show
hanishkvc Nov 16, 2025
9319ef2
SimpleChatTCRV:UICleanup: loading message wrt restoring session
hanishkvc Nov 16, 2025
c5c257f
SimpleChatTCRV:Cleanup:MouseEvents demote, UIRefreshy almost all
hanishkvc Nov 16, 2025
cc8057d
SimpleChatTCRV:Cleanup: Starting flow, cleanup description, readme
hanishkvc Nov 16, 2025
202d427
SimpleChatTCRV:UICleanup: User Input area one bunch of clenaup
hanishkvc Nov 16, 2025
4a36eb6
SimpleChatTCRV:UI Cleanup
hanishkvc Nov 17, 2025
667b81c
SimpleChatTCRV:UI theme simple cleanup
hanishkvc Nov 17, 2025
c0fac32
SimpleChatTCRV:UI theme simple cleanup - css round 2
hanishkvc Nov 17, 2025
21520b6
SimpleChatTCRV:UI theme cleanup - html+css r3
hanishkvc Nov 18, 2025
082a9a8
SimpleChatTCRV:UICleanup: PopOverTO, buttonBorder, Restore, Usage
hanishkvc Nov 18, 2025
61095ad
SimpleChatTCRV:UICleanup: Scrollbar, role gradiants, textarea, ...
hanishkvc Nov 18, 2025
d11b746
SimpleChatTCRV:UICleanup: limit border-radius, SlidingWindow info
hanishkvc Nov 18, 2025
5830afb
SimpleChatTCRV:UiCleanup: Switch to icon only buttons and title
hanishkvc Nov 18, 2025
9c65255
SimpleChatTCRV:UICleanup+: Fix oversight wrt Auto ObjPropsEdit
hanishkvc Nov 18, 2025
04be028
SimpleChatTCRV:UICleanup: Sessions button take one popover
hanishkvc Nov 18, 2025
e52754c
SimpleChatTCRV:Sessions++ button take two: normal html + js + css
hanishkvc Nov 18, 2025
7df4329
SimpleChatTCRV:SysDateTime: Follow unix date format markers
hanishkvc Nov 18, 2025
2c3a669
SimpleChatTCRV:UICleanup: ToolCall trigger and UserInput block
hanishkvc Nov 19, 2025
3d1ee49
SimpleChatTCRV:UICleanup:Popover Firefox work around
hanishkvc Nov 19, 2025
2ff76f5
SimpleChatTCRV:UICleanup: Full chat messages ui refresh when needed
hanishkvc Nov 19, 2025
bb4a323
SimpleChatTCRV:UICleanup: PopOver, Reasoning bubble
hanishkvc Nov 19, 2025
b4ba7b2
SimpleChatTCRV:UIClean:Free up vertical space
hanishkvc Nov 20, 2025
0e0aeb7
SimpleChatTCRV:MultipleImages:UI: Load track multiple images
hanishkvc Nov 20, 2025
340648e
SimpleChatTCRV:MultipleImages: Icon only buttons
hanishkvc Nov 20, 2025
3eda52a
SimpleChatTCRV:MultipleImages:Update ChatMessage++ wrt same
hanishkvc Nov 20, 2025
1a824ae
SimpleChatTCRV:UICleanup: Icon samples
hanishkvc Nov 20, 2025
f8c503d
SimpleChatTCRV:UICleanup: new icons short texts, tighter buttons
hanishkvc Nov 20, 2025
ea25bc9
SimpleChatTCRV:ImagePopOver: To view and if reqd del before submit
hanishkvc Nov 20, 2025
c711b0d
SimpleChatTCRV:AnveshikaSallap, Color cleanup
hanishkvc Nov 21, 2025
9fbd531
SimpleChatTCRV:UIClean: Avoid wip popover anchor position mech
hanishkvc Nov 21, 2025
a709b6c
SimpleChatTCRV:ToolCall:ExternalAi: initial go
hanishkvc Nov 21, 2025
48111df
SimpleChatTCRV:ToolCall Ai - Decouple SimpleChat from Me a bit
hanishkvc Nov 21, 2025
0666336
SimpleChatTCRV:DivStream: Allow predetermined div for streamd resp
hanishkvc Nov 21, 2025
533c8fa
SimpleChatTCRV:DivStreams: Have sep div for each chat session
hanishkvc Nov 21, 2025
a9c7f23
SimpleChatTCRV:DivStreams: Why missing - still a mystry
hanishkvc Nov 21, 2025
b90dc2e
SimpleChatTCRV:DivStreams: Prepared for switching in middle
hanishkvc Nov 21, 2025
d6537ee
SimpleChatTCRV:DivStreams: Enhanced Object using JSDoc++
hanishkvc Nov 22, 2025
a04fe99
SimpleChatTCRV:DivStream: Make it a class
hanishkvc Nov 22, 2025
81106bb
SimpleChatTCRV:ToolCall:ExternalAi: Show its response live
hanishkvc Nov 22, 2025
12295a4
SimpleChatTCRV:ToolCalls Cleanup
hanishkvc Nov 22, 2025
9765c72
SimpleChatTCRV:Config:WIP: Move config fields into a Config class
hanishkvc Nov 23, 2025
1fa940e
SimpleChatTCRV:Config:WIP:Switch SimpleChat to Config from Me
hanishkvc Nov 23, 2025
3a360fb
SimpleChatTCRV:Config+:WIP:CleanUp: Have sensible chatIds
hanishkvc Nov 23, 2025
dbe6c84
SimpleChatTCRV:Config:WIP:Temporary updated starting flow
hanishkvc Nov 23, 2025
73fbd60
SimpleChatTCRV:Config:Tools: Adapt for SimpleChat with Config
hanishkvc Nov 23, 2025
5c3a54f
SimpleChatTCRV:Config++: ValidatedToolCall UI updated
hanishkvc Nov 23, 2025
4685f1a
SimpleChatTCRV:Config++:Cleanup: Hide/Show UserIn and ValidateTC
hanishkvc Nov 23, 2025
d816d99
SimpleChatTCRV:Config++:Save/Load Configs
hanishkvc Nov 23, 2025
cfcb5ee
SimpleChatTCRV:Config++:Cleanup the initial go
hanishkvc Nov 23, 2025
3adbb49
SimpleChatTCRV:AnveshikaSallap: cleanup in general
hanishkvc Nov 24, 2025
32232e7
SimpleChatTCRV:UIRefresh cleanup: Show only msgs in sliding window
hanishkvc Nov 24, 2025
d44e002
SimpleChatTCRV:Cleanup
hanishkvc Nov 24, 2025
489d0c2
SimpleChatTCRV:Misc cleanup continues...
hanishkvc Nov 24, 2025
6af6b88
SimpleChatTCRV: Documentation cleanup
hanishkvc Nov 24, 2025
468b62f
SimpleChatTCRV: split changelog from details into separate file
hanishkvc Nov 24, 2025
893406d
SimpleChatTCRV: Add simple readme in place of detailed one
hanishkvc Nov 24, 2025
cf08592
SimpleChatTCRV: Update/Cleanup the new readme
hanishkvc Nov 24, 2025
5dede41
SimpleChatTCRV:Cleanup importmap
hanishkvc Nov 24, 2025
09ec474
SimpleChatTCRV:AiCallingAi ToolCall: flow cleanup and flexibility
hanishkvc Nov 24, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions tools/server/public_simplechat/datautils.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,9 @@ export function trim_hist_garbage_at_end(sIn, maxType, maxUniq, maxMatchLenThres
let iNum = 0;
let iOth = 0;
// Learn
/**
* @type {Object<string, number>}
*/
let hist = {};
let iUniq = 0;
for(let i=0; i<maxMatchLenThreshold; i++) {
Expand Down
335 changes: 335 additions & 0 deletions tools/server/public_simplechat/docs/changelog.md

Large diffs are not rendered by default.

663 changes: 663 additions & 0 deletions tools/server/public_simplechat/docs/details.md

Large diffs are not rendered by default.

133 changes: 133 additions & 0 deletions tools/server/public_simplechat/idb.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,133 @@
//@ts-check
// Helpers to handle indexedDB provided by browsers
// by Humans for All
//


/**
* Allows the db connection to be openned.
* @param {string} dbName
* @param {string} storeName
* @param {string} callerTag
*/
export function db_open(dbName, storeName, callerTag="") {
let tag = `iDB:${callerTag}`
return new Promise((resolve, reject) => {
const dbConn = indexedDB.open(dbName, 1);
dbConn.onupgradeneeded = (ev) => {
console.debug(`DBUG:${tag}:Conn:Upgrade needed...`)
dbConn.result.createObjectStore(storeName);
dbConn.result.onerror = (ev) => {
console.info(`ERRR:${tag}:Db:Op failed [${ev}]...`)
}
};
dbConn.onsuccess = (ev) => {
console.debug(`INFO:${tag}:Conn:Opened...`)
resolve(dbConn.result);
}
dbConn.onerror = (ev) => {
console.info(`ERRR:${tag}:Conn:Failed [${ev}]...`)
reject(ev);
}
});
}


/**
* Get hold of a transaction wrt a specified store in the db
* @param {IDBDatabase} db
* @param {string} storeName
* @param {IDBTransactionMode} opMode
*/
export function db_trans_store(db, storeName, opMode) {
let dbTrans = db.transaction(storeName, opMode);
let dbOS = dbTrans.objectStore(storeName);
return dbOS
}


/**
* Put a given key-value pair into a store in a db.
* Return success or failure through callback.
*
* @param {string} dbName
* @param {string} storeName
* @param {IDBValidKey} key
* @param {any} value
* @param {string | undefined} callerTag
* @param {(status: boolean, related: IDBValidKey | DOMException | null) => void} cb
*/
export function db_put(dbName, storeName, key, value, callerTag, cb) {
let tag = `iDB:Put:${callerTag}`;
db_open(dbName, storeName, tag).then((/** @type {IDBDatabase} */db)=>{
let reqPut = db_trans_store(db, storeName, 'readwrite').put(value, key)
reqPut.onerror = (evPut) => {
console.info(`ERRR:${tag}:OnError:transact failed:${reqPut.error}`)
cb(false, reqPut.error)
}
reqPut.onsuccess = (evPut) => {
console.info(`DBUG:${tag}:transact success`)
cb(true, reqPut.result)
}
}).catch((errReason)=>{
console.info(`ERRR:${tag}:Caught:transact failed:${errReason}`)
cb(false, errReason)
})
}


/**
* Return value of specified key from a store in a db,
* through the provided callback.
*
* @param {string} dbName
* @param {string} storeName
* @param {IDBValidKey} key
* @param {string | undefined} callerTag
* @param {(status: boolean, related: IDBValidKey | DOMException | null) => void} cb
*/
export function db_get(dbName, storeName, key, callerTag, cb) {
let tag = `iDB:Get:${callerTag}`;
db_open(dbName, storeName, tag).then((/** @type {IDBDatabase} */db)=>{
let reqGet = db_trans_store(db, storeName, 'readonly').get(key);
reqGet.onsuccess = (evGet) => {
console.info(`DBUG:${tag}:transact success`)
cb(true, reqGet.result)
}
reqGet.onerror = (evGet) => {
console.info(`ERRR:${tag}:OnError:transact failed:${reqGet.error}`)
cb(false, reqGet.error)
}
}).catch((errReason)=>{
console.info(`ERRR:${tag}:Caught:transact failed:${errReason}`)
cb(false, errReason)
})
}


/**
* Return all keys from a store in a db,
* through the provided callback.
*
* @param {string} dbName
* @param {string} storeName
* @param {string | undefined} callerTag
* @param {(status: boolean, related: IDBValidKey[] | DOMException | null) => void} cb
*/
export function db_getkeys(dbName, storeName, callerTag, cb) {
let tag = `iDB:GetKeys:${callerTag}`;
db_open(dbName, storeName, tag).then((/** @type {IDBDatabase} */db)=>{
let reqGet = db_trans_store(db, storeName, 'readonly').getAllKeys();
reqGet.onsuccess = (evGet) => {
console.info(`DBUG:${tag}:transact success`)
cb(true, reqGet.result)
}
reqGet.onerror = (evGet) => {
console.info(`ERRR:${tag}:OnError:transact failed:${reqGet.error}`)
cb(false, reqGet.error)
}
}).catch((errReason)=>{
console.info(`ERRR:${tag}:Caught:transact failed:${errReason}`)
cb(false, errReason)
})
}
56 changes: 42 additions & 14 deletions tools/server/public_simplechat/index.html
Original file line number Diff line number Diff line change
@@ -1,49 +1,77 @@
<!DOCTYPE html>
<html lang="en">
<head>
<title>SimpleChat LlamaCppEtal </title>
<title>SimpleChat/AnveshikaSallap LlamaCppEtal </title>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<meta name="message" content="Save Nature Save Earth" />
<meta name="description" content="SimpleChat: trigger LLM web service endpoints /chat/completions and /completions, single/multi chat sessions" />
<meta name="description" content="SimpleChat/AnveshikaSallap: trigger LLM web service endpoints /chat/completions and /completions, multiple chat sessions with own settings, tool calling with builtin tool calls, reasoning, vision" />
<meta name="author" content="by Humans for All" />
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
<script type="importmap">
{
"imports": {
"simplechat": "./simplechat.js",
"datautils": "./datautils.mjs",
"ui": "./ui.mjs"
"ui": "./ui.mjs",
"toolsmanager": "./tools.mjs"
}
}
</script>
<script src="simplechat.js" type="module" defer></script>
<script src="main.js" type="module" defer></script>
<link rel="stylesheet" href="simplechat.css" />
</head>
<body>
<div class="samecolumn" id="fullbody">

<div class="sameline" id="heading">
<p class="heading flex-grow" > <b> SimpleChat </b> </p>
<button id="settings">Settings</button>
<div id="sessions-div" class="flex-grow"></div>
<div id="icons-div" class="flex-nogrow">
<button id="sessionsprompts" title="system prompts">&#x1F916;prompt</button>
<button id="clearchat" title="clear current chat">&#x1F300;clear</button>
<button id="settings" title="change settings">&#x2699;</button>
</div>
</div>

<div id="sessions-div" class="sameline"></div>

<hr>
<div class="sameline">
<label for="system-in">System</label>
<textarea name="system" id="system-in" rows="2" placeholder="e.g. you are a helpful ai assistant, who provides concise answers" class="flex-grow"></textarea>
<div id="sessionsprompts-div" class="visibility-visible">
<hr>
<div class="sameline role-system">
<label for="system-in">System</label>
<textarea name="system" id="system-in" rows="2" placeholder="e.g. you are a helpful ai assistant, who provides concise answers" class="flex-grow"></textarea>
</div>
</div>

<hr>
<div id="chat-div">
<p> You need to have javascript enabled.</p>
</div>

<div id="popover-chatmsg" popover="auto">
<button id="popover-chatmsg-del" title="delete message"> &#x274C; </button>
<button id="popover-chatmsg-copy" title="copy message text"> &#x1F4CB; </button>
</div>

<div id="tool-div">
<div class="sameline">
<textarea id="toolname-in" class="flex-grow" rows="1" placeholder="name of tool to run"></textarea>
<button id="tool-btn">run tool</button>
</div>
<div class="sameline">
<textarea id="toolargs-in" class="flex-grow" rows="2" placeholder="arguments to pass to the specified tool"></textarea>
</div>
</div>

<hr>
<div class="sameline">
<div id="popover-image" popover="auto">
<img id="poimage-img"></img>
<button id="poimage-del" title="delete"> &#x274C; </button>
</div>
<div id="user-in-div" class="role-user">
<div id="user-in-imgs"></div>
<div class="sameline">
<textarea id="user-in" class="flex-grow" rows="2" placeholder="enter your query to the ai model here" ></textarea>
<button id="user-btn">submit</button>
<button id="user-btn" title="submit">&#x1F4AC;</button>
</div>
</div>

</div>
Expand Down
24 changes: 24 additions & 0 deletions tools/server/public_simplechat/local.tools/debug.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Helpers for debugging
# by Humans for All


import time

gMe = { '--debug' : False }


def setup(bEnable):
global gMe
gMe['--debug'] = bEnable


def dump(meta: dict, data: dict):
if not gMe['--debug']:
return
timeTag = f"{time.time():0.12f}"
with open(f"/tmp/simpleproxy.{timeTag}.meta", '+w') as f:
for k in meta:
f.write(f"\n\n\n\n{k}:{meta[k]}\n\n\n\n")
with open(f"/tmp/simpleproxy.{timeTag}.data", '+w') as f:
for k in data:
f.write(f"\n\n\n\n{k}:{data[k]}\n\n\n\n")
81 changes: 81 additions & 0 deletions tools/server/public_simplechat/local.tools/filemagic.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# Handle file related helpers, be it a local file or one on the internet
# by Humans for All

import urllib.request
import urllib.parse
import debug
from dataclasses import dataclass


@dataclass(frozen=True)
class Response:
"""
Used to return result wrt urlreq helper below.
"""
callOk: bool
statusCode: int
statusMsg: str = ""
contentType: str = ""
contentData: bytes = b""



def get_from_web(url: str, tag: str, inContentType: str, inHeaders: dict[str, str|None]):

Check failure on line 23 in tools/server/public_simplechat/local.tools/filemagic.py

View workflow job for this annotation

GitHub Actions / pyright type-check

Alternative syntax for unions requires Python 3.10 or newer (reportGeneralTypeIssues)
"""
Get the url specified from web.

If passed header doesnt contain certain useful http header entries,
some predefined defaults will be used in place.
"""
try:
hUA = inHeaders.get('User-Agent', None)
if not hUA:
hUA = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:132.0) Gecko/20100101 Firefox/132.0'
hAL = inHeaders.get('Accept-Language', None)
if not hAL:
hAL = "en-US,en;q=0.9"
hA = inHeaders.get('Accept', None)
if not hA:
hA = "text/html,*/*"
headers = {
'User-Agent': hUA,
'Accept': hA,
'Accept-Language': hAL
}
req = urllib.request.Request(url, headers=headers)
# Get requested url
print(f"DBUG:{tag}:Req:{req.full_url}:{req.headers}")
with urllib.request.urlopen(req, timeout=10) as response:
contentData = response.read()
statusCode = response.status or 200
statusMsg = response.msg or ""
contentType = response.getheader('Content-Type') or inContentType
print(f"DBUG:FM:GFW:Resp:{response.status}:{response.msg}")
debug.dump({ 'op': 'FileMagic.GetFromWeb', 'url': req.full_url, 'req.headers': req.headers, 'resp.headers': response.headers, 'ctype': contentType }, { 'cdata': contentData })
return Response(True, statusCode, statusMsg, contentType, contentData)
except Exception as exc:
return Response(False, 502, f"WARN:{tag}:Failed:{exc}")


def get_from_local(urlParts: urllib.parse.ParseResult, tag: str, inContentType: str):
"""
Get the requested file from the local filesystem
"""
try:
fPdf = open(urlParts.path, 'rb')
dPdf = fPdf.read()
return Response(True, 200, "", inContentType, dPdf)
except Exception as exc:
return Response(False, 502, f"WARN:{tag}:Failed:{exc}")


def get_file(url: str, tag: str, inContentType: str, inHeaders: dict[str, str|None]={}):

Check failure on line 72 in tools/server/public_simplechat/local.tools/filemagic.py

View workflow job for this annotation

GitHub Actions / pyright type-check

Alternative syntax for unions requires Python 3.10 or newer (reportGeneralTypeIssues)
"""
Based on the scheme specified in the passed url,
either get from local file system or from the web.
"""
urlParts = urllib.parse.urlparse(url)
if urlParts.scheme == "file":
return get_from_local(urlParts, tag, inContentType)
else:
return get_from_web(url, tag, inContentType, inHeaders)
Loading
Loading