Commit graph

48 commits

Author SHA1 Message Date
mpstaton
d5e78076f6 update(dependencies): update all dependencies for Perplexed
On branch development
 Your branch is ahead of 'origin/development' by 1 commit.
   (use "git push" to publish your local commits)
 Changes to be committed:
	deleted:    .eslintignore
	deleted:    .eslintrc
	new file:   changelog/2026-05-02_01.md
	new file:   eslint.config.mjs
	modified:   package.json
	modified:   pnpm-lock.yaml
	modified:   src/services/perplexityService.ts
	modified:   styles.css
	modified:   tsconfig.json
2026-05-02 01:08:20 -05:00
mpstaton
a13b4e2292 Update styles.css 2025-11-14 14:35:58 +00:00
mpstaton
f75afbfe58 Add WARP.md documentation for development workflow 2025-11-14 14:25:16 +00:00
TanujKS
153894fa09 improve: Deep Research Streaming \nfeat: Enhance Text and Add Image from selection commands 2025-08-28 23:44:58 -07:00
TanujKS
f0ef900a13 improve: Deep Research Streaming \nfeat: Enhance Text and Add Image from selection commands 2025-08-28 23:44:17 -07:00
mpstaton
3e7eb3b51c update(styles): update css styles
On branch development
 Your branch is up to date with 'origin/development'.
 Changes to be committed:
	modified:   styles.css
2025-08-13 16:21:48 +02:00
Tanuj Siripurapu
70a2f31136 fixed image placement and added setting to position query at top or end of response 2025-08-11 23:47:14 -04:00
mpstaton
bf8f02221f fix(streaming): fix streaming for chat query.
On branch feature/perplexity-streaming
 Changes to be committed:
	modified:   README.md
	new file:   src/docs/Understanding-the-Perplexity-Response-Object.md
	modified:   src/services/lmStudioService.ts
	modified:   src/services/perplexicaService.ts
	modified:   src/services/perplexityService.ts
	new file:   src/utils/formatDate.ts
	modified:   styles.css
	new file:   test-perplexity-api.sh
	new file:   test-perplexity-non-streaming.sh
2025-08-08 19:10:06 +02:00
TanujKS
8b3149ee67 feat(prompts) All prompts can now be configured in settings 2025-07-23 13:19:10 -07:00
TanujKS
ef85565f19 improve(modal) All modals now inject the required prompt to place images THROUGHOUT a file 2025-07-22 13:37:21 -07:00
TanujKS
ee286d2330 feat: Refactor plugin architecture and enhance UI/UX
- Split monolithic main.ts into modular services and modals
- Created separate service classes: PerplexityService,
  PerplexicaService, LMStudioService
  - Created modular modal classes: PerplexityModal, PerplexicaModal,
    LMStudioModal, URLUpdateModal
    - Deleted unused legacy files: CitationModal.ts, citationService.ts,
      cleanReferencesSectionService.ts

      ## New Features
      - Added ArticleGeneratorModal for one-page article generation with
	predefined prompts
	- Implemented intelligent image placement with [IMAGE n:
	  description] markers
	  - Added auto-scrolling during streaming responses for better
	    UX
	    - Created full callout formatting for query blocks with
	      multi-line support

	      ## UI/UX Improvements
	      - Moved all inline styles to dedicated CSS files for
		better maintainability
		- Created modular CSS structure: perplexity-modal.css,
		  article-generator-modal.css, etc.
		  - Added proper spacing and padding to text inputs
		    across all modals
		    - Fixed sources placement to appear after last
		      non-empty line (no more huge gaps)
		      - Enhanced modal layouts with better visual
			hierarchy

			## Build System
			- Updated esbuild.config.mjs to properly bundle
			  CSS files
			  - Created src/styles/main.css as CSS entry
			    point
			    - Implemented proper CSS build process with
			      minification support

			      ## Bug Fixes
			      - Fixed TypeScript errors from unused
				imports and parameters
				- Resolved streaming scroll issues with
				  proper cursor tracking
				  - Fixed multi-line query formatting in
				    callout blocks
				    - Corrected sources insertion logic
				      for both streaming and
				      non-streaming responses

				      ## Code Quality
				      - Improved separation of concerns
					with service/modal architecture
					- Enhanced maintainability with
					  modular CSS structure
					  - Added comprehensive error
					    handling and logging
					    - Implemented consistent
					      coding patterns across all
					      services

					      ## Technical Details
					      - Services now handle API
						calls, streaming, and
						response processing
						- Modals focus purely on
						  UI and user
						  interaction
						  - CSS uses Obsidian's
						    design system
						    variables for
						    theming
						    - All modals support
						      both streaming and
						      non-streaming
						      modes
						      - Image placement
							supports both
							inline markers
							and fallback
							sections

							Breaking
							Changes: None
							Migration:
							Existing
							functionality
							preserved,
							enhanced with
							new features
2025-07-20 16:32:36 -07:00
mpstaton
15bbc0f565 improve(settings), new(api): add new LM Studio API, improve settings
On branch development
 Your branch is up to date with 'origin/development'.
 Changes to be committed:
	modified:   README.md
	modified:   main.ts
	modified:   styles.css
2025-07-20 01:48:39 +03:00
mpstaton
b01599a617 fix(typescript): fix typescript error
On branch development
 Your branch is up to date with 'origin/development'.
 Changes to be committed:
	modified:   main.ts
2025-07-19 23:11:01 +03:00
mpstaton
7b1364098e attempt(api-images): attempt to process API related image responses
On branch development
 Your branch is up to date with 'origin/development'.
 Changes to be committed:
	modified:   main.ts
2025-07-19 22:40:18 +03:00
mpstaton
880a442911 milestone(streaming): api-call to Perplexity as made through modal now
works and streams responses back.  Not perfect, but works!

 On branch development
 Your branch is up to date with 'origin/development'.
 Changes to be committed:
	modified:   main.ts
2025-07-19 21:33:08 +03:00
mpstaton
0e8b4ca114 milestone(settings): settings panel is better than good enough
On branch development
 Your branch is ahead of 'origin/development' by 1 commit.
   (use "git push" to publish your local commits)
 Changes to be committed:
	modified:   README.md
	modified:   main.ts
2025-07-19 21:13:34 +03:00
mpstaton
c81ca99aa8 improve(settings): improve settings UI
On branch development
 Your branch is up to date with 'origin/development'.
 Changes to be committed:
	modified:   main.ts
	new file:   package-lock.json
	modified:   package.json
	modified:   styles.css
2025-07-19 21:08:45 +03:00
mpstaton
7e6831c315 init(project): initial commit for Perplexed Obsidian Plugin with basic readme, manifest, package.json
On branch master
 Changes to be committed:
	modified:   README.md
	modified:   manifest.json
	modified:   package.json
2025-07-10 00:00:49 +03:00
mpstaton
7e2aeb7bb5 update(packages): updated packages and dependencies to latest
On branch master
 Your branch is up to date with 'origin/master'.
 Changes to be committed:
	modified:   package.json
	modified:   pnpm-lock.yaml
2025-07-09 23:34:17 +03:00
mpstaton
708e4a18c6 Merge development into master 2025-07-09 23:21:45 +03:00
mpstaton
5de4339c6c save(state): save state of starter code for any obsidian plugin
On branch development
 Changes to be committed:
	deleted:    .cursor/mcp.json
	deleted:    .windsurfrules
	modified:   README.md
	modified:   manifest.json
	modified:   package.json
	modified:   versions.json
2025-07-09 23:18:48 +03:00
mpstaton
cee8c2647c feat(move-citations): rearrange format by moving citations behind commas and periods.
- Move citations after punctuation (periods and commas) in document body
- Preserve reference section formatting
- Handle multiple citations before punctuation
- Add proper spacing between multiple citations
- Process entire document in one pass
- Add command to format citations via command palette

The command "Move Citations after Punctuation" is now available in the command palette (Ctrl/Cmd+P) to format citations throughout the document.
 On branch development
 Changes to be committed:
	modified:   main.ts
	modified:   src/services/citationService.ts
2025-07-08 20:12:25 +03:00
mpstaton
3d0eb2ac06 feat(clean-references): add reference cleanup service with colon formatting
- Implement cleanReferencesSectionService with addColonSyntaxWhereNone function
- Add command to format footnote references with consistent colon syntax
- Fix regex to handle various footnote reference formats
- Preserve leading whitespace and ensure single space after colon
- Add TypeScript type safety with proper null checks
- Integrate with main plugin command registry

The new command formats footnote references from:
  [^hexId] Text...
to:
  [^hexId]: Text...

This improves consistency in citation formatting throughout documents.
 On branch development
 Changes to be committed:
	modified:   main.ts
	new file:   src/services/cleanReferencesSectionService.ts
2025-07-08 19:24:11 +03:00
mpstaton
39945546a1 save(modal): save to hex modal as it mostly works
On branch development
 Changes to be committed:
	modified:   src/services/citationService.ts
2025-07-08 19:05:06 +03:00
mpstaton
262b2e95a9 feature(modal): covert citations modal now works
On branch development
 Changes to be committed:
	modified:   src/services/citationService.ts
2025-07-08 15:10:44 +03:00
mpstaton
6d616c9a63 improve(modal): isolate final reference for conversion to hex
On branch development
 Changes to be committed:
	modified:   src/modals/CitationModal.ts
	modified:   src/services/citationService.ts
	modified:   src/styles/citations.css
2025-07-08 03:29:52 +03:00
mpstaton
7337a11172 improve(modal): improve line identification in modal
On branch development
 Changes to be committed:
	modified:   src/services/citationService.ts
2025-07-08 02:54:29 +03:00
mpstaton
cf09cfa2c1 improve(modal): improve to hex modal by creating a pre-process function
On branch development
 Changes to be committed:
	modified:   src/services/citationService.ts
2025-07-08 02:39:49 +03:00
mpstaton
9f6cbfd4c0 progress(modal): progress on citations modal, now isolates single
citations

 On branch development
 Changes to be committed:
	modified:   src/modals/CitationModal.ts
	modified:   src/services/citationService.ts
	modified:   src/styles/citations.css
2025-07-08 02:12:40 +03:00
mpstaton
ad3303c0e8 iterate(modal): rebuild of modal code
- Fixed method name mismatch between convertCitation and convertCitations
- Made generateHexId private and added public getNewHexId method
- Improved type safety for CitationMatch interface with explicit URL handling
- Cleaned up unused imports and variables in CitationModal
- Fixed file handling to use correct Obsidian API types
- Updated citation conversion logic to handle multiple groups
- Added proper error handling for file operations
- Improved code documentation and type annotations
- Formatted styles.css for better readability
2025-07-08 01:55:44 +03:00
mpstaton
08631c7264 iterate(modal): iterate on CitationModal to isolate one integer at a
time

 On branch development
 Changes to be committed:
	modified:   src/modals/CitationModal.ts
	modified:   src/services/citationService.ts
2025-07-07 23:55:40 +03:00
mpstaton
a957050575 iterate(modal): iterate on CitationModal
On branch development
 Changes to be committed:
	modified:   src/modals/CitationModal.ts
2025-07-07 20:19:08 +03:00
mpstaton
28e713509c iterate(to-hex): iterate on functions transforming Perplexity style
footnotes

Enhanced Type Safety:
Made the type property more specific with a union type: 'footnote' | 'reference' | 'perplexity'
Made lineContent a required property since we always want to track the line context
Added proper null checks for regex match groups
Improved Citation Matching:
Now properly handles three types of citations:
Standard footnotes: [^1]
Standard citations: [1] (excluding markdown links)
Perplexity-style footnotes: 1. [https://example.com]
Added proper line-by-line processing to handle Perplexity-style footnotes correctly
Improved position tracking to handle multi-line content
Better Error Handling:
Added null checks for regex matches
More precise error messages
Better handling of edge cases
Fixed TypeScript Errors:
Ensured all required properties are properly typed
Removed any unsafe type assertions
Made the code more type-safe with proper interfaces
Improved Code Organization:
Better function documentation
More consistent variable naming
Cleaner control flow

 On branch development
 Changes to be committed:
	modified:   src/services/citationService.ts
2025-07-07 19:42:45 +03:00
mpstaton
364243aa40 progress(tohex): progress on to hex transformation from CitationModal
On branch development
 Changes to be committed:
	modified:   src/services/citationService.ts
2025-07-07 14:45:40 +03:00
mpstaton
90f7d18b12 prerun(toHex): save attempt at citation modal based on new spec
On branch development Changes to be committed:
modified:   src/modals/CitationModal.ts
modified:   src/services/citationService.ts
2025-07-07 14:25:30 +03:00
mpstaton
0cb22b7450 start(button): start "to hex" button in modal
On branch development
 Changes to be committed:
	modified:   src/modals/CitationModal.ts
	modified:   src/styles/citations.css
	modified:   styles.css
2025-07-06 18:48:32 +03:00
mpstaton
bc051168d1 feat(modal): milestone of modal feature displaying citations working
On branch development
 Changes to be committed:
	modified:   README.md
	modified:   esbuild.config.mjs
	modified:   main.ts
	modified:   manifest.json
	new file:   src/modals/CitationModal.ts
	new file:   src/services/citationService.ts
	new file:   src/styles/citations.css
	new file:   src/types/obsidian.d.ts
	new file:   src/utils/logger.ts
2025-07-06 18:41:26 +03:00
mpstaton
220876d2a5 clean(starter): clean starter code
On branch master
 Your branch is up to date with 'origin/master'.
 Changes to be committed:
	modified:   .gitignore
	modified:   .windsurfrules
	modified:   README.md
	modified:   package.json
2025-07-06 17:23:37 +03:00
mpstaton
ffc16b55e0 Initial commit for cite-wide 2025-07-06 17:09:30 +03:00
mpstaton
644582d3dd add(packages): add Fastify, MCP, and Zod
On branch development
 Changes to be committed:
	modified:   package.json
	modified:   pnpm-lock.yaml
2025-06-08 00:51:01 +03:00
mpstaton
7388cb3912 fix(citations): fix inline hex citations
On branch development
 Changes to be committed:
	modified:   main.ts
2025-06-07 23:51:13 +03:00
mpstaton
ac92170d96 milestone(perplexica): write to file now works correctly
On branch development
 Changes to be committed:
	modified:   main.ts
2025-06-07 21:53:11 +03:00
mpstaton
e83d8f457e milestone(perplexica): now hitting perplexica
On branch development
 Changes to be committed:
	modified:   main.ts
2025-06-07 21:22:27 +03:00
mpstaton
f394ef7253 feat(hexCitations): added hex citations to functionality
On branch development
 Changes to be committed:
	modified:   main.ts
2025-06-07 20:09:33 +03:00
mpstaton
424b7871fc upgrade(packages): all packages are now up to date
On branch development
 Changes to be committed:
	modified:   .eslintrc
	modified:   esbuild.config.mjs
	modified:   main.ts
	modified:   package.json
	modified:   pnpm-lock.yaml
	modified:   tsconfig.json
2025-06-07 19:20:42 +03:00
mpstaton
1f74e2d86a update(packages): update several packages not breaking
On branch master
 Your branch is up to date with 'origin/master'.
 Changes to be committed:
	modified:   package.json
	modified:   pnpm-lock.yaml
2025-06-07 18:55:24 +03:00
mpstaton
0145a51fd7 switch(pnpm): add pnpm get rid of npm
On branch master
 Your branch is up to date with 'origin/master'.
 Changes to be committed:
	modified:   .npmrc
	deleted:    lcontent-farm.code-workspace
	modified:   main.ts
	deleted:    package-lock.json
	modified:   package.json
	new file:   pnpm-lock.yaml
	modified:   versions.json
2025-06-07 18:25:25 +03:00
mpstaton
fbfaa55bf7 start(project): initial setup from example Obsidian plugin with our developer preferences 2025-06-07 15:37:58 +03:00