Giter VIP home page Giter VIP logo

logseq-copilot's Introduction

👋 Welcome

I'm EINDEX, an Application Security Specialist at @Thoughtworks.

With a strong background in the field of application security, I specialize in various areas such as Threat modeling, Application Security Review, Python, and more.

Here are a couple of my notable projects:

You can connect with me through various channels:

logseq-copilot's People

Contributors

eindex avatar fossabot avatar gissehel avatar howarddo2208 avatar jaeyeopme avatar yuhangch avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

logseq-copilot's Issues

feature request: support kagi

Is your feature request related to a problem? Please describe.
I'm using kagi, a fast, privacy conscious search
Describe the solution you'd like
support kagi

Links popup: refs to block/page do not work

Describe the bug
Links clicking do nothing (in popup).
PS: no errors in console.

To Reproduce
Steps to reproduce the behavior:

  1. add link to Logseq
  2. open url
  3. see green dot on pluign icon
  4. click on it
  5. see popup with logseq results
  6. clicking "open block/page" do nothing

Expected behavior
links works as in right side inline block and opens Logseq deeplink with page

Screenshots
image

Desktop (please complete the following information):

  • OS: Win10
  • Browser: Chrome latest
  • Copilot: 1.9.1

Extension error

I have this error, see screenshot:

Screenshot 2023-02-14 at 10 56 07 AM

It is working right now but sometimes it will not show results. I run this alongside other few extensions particularly ChatGPT for Google.

My machine:

MacOS Intel running latest Ventura
Arc browser

Cannot show query result.

Chrome:102, copilot : 1.11.3
Save is work, icon will show correct saved item counts.
But click the icon, cannot show query result.

snap_20230508_160438_chrome

I checked service work log:
snap_20230508_155733_chrome

feat: website recall rule function

Describe the bug
When accessing a normal video (not a short video) on the YouTube website. The Logseq Copilot icon displays incorrect numbers. This behavior only occurs on the YouTube website, while other websites function normally.

To Reproduce
Steps to reproduce the behavior:

  1. Go to 'youtube.com' in internet browser
  2. Open any video (not short)
  3. View the Logseq Copilot icon
  4. Pay attention to the numbers displayed

Expected behavior
The Logseq Copilot icon should not display any numbers if the video we are watching is a video that has not been clipped. If the video has been clipped (for example 3 times) then the number that appears should be 3.

Screenshots

I have never clipped this video. But look at the number displayed by Logseq Copilot, 208.
Screen Shot 2024-02-22 at 20 27 49

I've already clipped this video once. But Logseq Copilot displays the number 208 instead of 1.
Screen Shot 2024-02-22 at 20 33 38

I've clipped this short twice. Logseq Copilot displays the number correctly which is 2.
Screen Shot 2024-02-22 at 20 10 19

This is an example from another website, Github. I have already clipped this webpage once. And Logseq Copilot displays the correct number, which is 1.
Screen Shot 2024-02-22 at 15 18 35

Desktop:

  • OS: MacOS 10.15.7 (19H2026)
  • Browser: Chrome 122.0.6261.57 (Official Build) (x86_64)
  • Logseq Copilot 1.13.2
  • Logseq 0.10.6

Background page not resumed when sending clip

Describe the bug
It seem, that the connection or background page is unloaded.
Selecting a text and clipping it, does not work. Opening the settings page is enough that after closing the sending works as intended.

To Reproduce
Steps to reproduce the behavior:

  1. Go to "send does not work"
  2. go to settings page and see it connect
  3. The text should still be selected. Pressing the send button again will delete the selection and success

Expected behavior
Should work at the first try

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser firefox
  • Version 119

Additional context
Add any other context about the problem here.

{{url}} and {{title}} is undefined

Describe the bug
Clicking on the quick capture icon often results in {{url}} and {{title}} expands to 'undefined'.

To Reproduce
Steps to reproduce the behavior:

  1. Open Firefox or Vivaldi.
  2. Open a new tab and go to some website.
  3. Select some text and click on the quick capture popup.
  4. Switch to logseq and check the capture.
  5. Note: Url and title are 'undefined'
  6. Now switch to the browser
  7. Click on the logseq copilot extension icon on the toolbar.
  8. Now quick capture again.
  9. Note: Url and title filled.

Expected behavior
Url and title always filled.

Desktop (please complete the following information):

  • OS: archlinux
  • Browser: Firefox 112.0, Vivaldi 5.7.2921.65

Additional context
This can be fixed by adding 'tabs' permission to manifest.json.
As explained in https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/permissions#api_permissions
you need this permission for tabs.url and tabs.title.

And as in https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/permissions#activetab_permission
you can read the url and title of the active tab, but only after the user clicks the extension icon.

Feature: Implement send tabs to logseq / restore

Is your feature request related to a problem? Please describe.
We could use logseq to manage groups of tabs/ontab but combined with logseq.
This way, we could structure our research to topics in logseq, but also hybernate the accompaning browser window with it.

Describe the solution you'd like

  • Each Window has a Topic, which correspons to the page in logseq. Can be set in the extension window.

  • Add a Button: Suspend to logseq (with warning please ;)
    This adds/edits the page with a special block that links to all the tabs and to the session id that is used to hybernate the window. Like a real session manager does, with forms etc

In logseq we need a plugin:

  • The block gets rendered with a button resume session.
    This opens a new browser window with all tabs restored.

feat: Clip at Chrome PDF file views

Describe the bug
I'm opening a pdf file within Google Chrome. When I highlight a text paragraph and right click on Clip, nothing happens.

To Reproduce
Steps to reproduce the behavior:

  1. Open a PDF file in Google Chrome
  2. Highlight text
  3. Right click and select Clip
  4. Nothing happens

Expected behavior
I expect to have the clip saved to the Journal.

Desktop (please complete the following information):

  • OS: [macOS Sonoma]
  • Browser [chrome]
  • Version 122.0.6261.69 (Official Build) (arm64)

Additional context
If you don't support that feature yet, I suggest you remove the "Clip" option when right-clicking a text highlight.

How to support multi graph?

How to support multi graphs?
I have 2 graphs, one for work , another for the life.
How to connect the 2 graphs with copilot?

  • I can choice the graph when i save the content.
  • In google search page, show 2 graphs result at side panel.

The automated release is failing 🚨

🚨 The automated release from the release branch failed. 🚨

I recommend you give this issue a high priority, so other packages depending on you can benefit from your bug fixes and new features again.

You can find below the list of errors reported by semantic-release. Each one of them has to be resolved in order to automatically publish your package. I’m sure you can fix this 💪.

Errors are usually caused by a misconfiguration or an authentication problem. With each error reported below you will find explanation and guidance to help you to resolve it.

Once all the errors are resolved, semantic-release will release your package the next time you push a commit to the release branch. You can also manually restart the failed CI job that runs semantic-release.

If you are not sure how to resolve this, here are some links that can help you:

If those don’t help, or if this issue is reporting something you think isn’t right, you can always ask the humans behind semantic-release.


Cannot push to the Git repository.

semantic-release cannot push the version tag to the branch release on the remote Git repository with URL https://x-access-token:[secure]@github.com/eindex/logseq-copliot.git.

This can be caused by:


Good luck with your project ✨

Your semantic-release bot 📦🚀

[Feature request] User adjustable debounce timer on floating button.

Is your feature request related to a problem? Please describe.
I was wondering why i couldn't clip the content using the floating button unless i double click the button, so i went into the source code and found out that there was a debounce timer in QuickCapture.tsx with 100ms, finding that i tried clicking just once super fast and then it works.

Describe the solution you'd like
I would love to see an option to adjust the debounce timer because the default behavior imo seems like a bug, since when you click for not even a long duration such as a quarter second/half a second of hold time the button pops up next to your cursor and there is no feedback to the user that they were too slow, leading to them trying to click at the same speed again leading to the button going to the bottom right the more the user clicks it.

Describe alternatives you've considered
You could also raise the debounce timer to 250ms instead of the 100ms as it is right now, or remove the debounce entirely.

Additional context
First time user here and this behavior threw me off and i thought the extension was bugged and the button wasn't listening to inputs due to me using firefox and not chrome since that is the most popular browser.

Refine the error message in Options page when can't connect to Logseq

Currently when clicking the connect button and it fails, the error message is "Unknow issues, may you can connect with author".

  1. Should be "Unknown issues. Maybe you can contact with the author.".

  2. More importantly, most often this error is because Logseq is not running, or the API Server is not started. So, instead of "contact with the author", we should prompt the user to check these first. E.g. :

[Connection failed] (button)
(text) Can't connect to the Logseq API Server. Please check that:
  1. Logseq is running.
  2. Logseq API Server is started. ((link)Guide)
  3. The Logseq host and token entered above are correct. 
  1. API Server doesn't need Developer Mode in the latest Logseq, so the setup guide should be changed accordingly.

The automated release is failing 🚨

🚨 The automated release from the main branch failed. 🚨

I recommend you give this issue a high priority, so other packages depending on you can benefit from your bug fixes and new features again.

You can find below the list of errors reported by semantic-release. Each one of them has to be resolved in order to automatically publish your package. I’m sure you can fix this 💪.

Errors are usually caused by a misconfiguration or an authentication problem. With each error reported below you will find explanation and guidance to help you to resolve it.

Once all the errors are resolved, semantic-release will release your package the next time you push a commit to the main branch. You can also manually restart the failed CI job that runs semantic-release.

If you are not sure how to resolve this, here are some links that can help you:

If those don’t help, or if this issue is reporting something you think isn’t right, you can always ask the humans behind semantic-release.


The item cannot be updated now because it is in pending review, ready to publish, or deleted status.

Unfortunately this error doesn't have any additional information. Feel free to kindly ask the author of the semantic-release-chrome plugin to add more helpful information.


Good luck with your project ✨

Your semantic-release bot 📦🚀

DuckDuckGo dark theme is unreadable

Describe the bug

When using the DuckDuckGo dark theme some parts of the copilot sidebar are unreadable.

To Reproduce
Steps to reproduce the behavior:

  1. Go to DuckDuckGo
  2. Switch to dark theme in settings
  3. Search for something that is available in the local graph
  4. See result

Expected behavior

The colors should have a better contrast in the dark theme.

Screenshots
If applicable, add screenshots to help explain your problem.

Default white theme

grafik

Switch to dark theme

grafik

Dark theme

grafik

Desktop (please complete the following information):

  • OS: Windows 11
  • Browser: Firefox
  • Version: 112

Is it possible to add a fuzzy search function?

Is your feature request related to a problem? Please describe.
I found this plugin to be very helpful when I started collecting data from various websites. However, I encountered a problem when trying to take notes for a specific website. The plugin only matches the note with the exact URL, whereas I would like it to detect any notes I wrote on a certain URL.

Describe the solution you'd like
My suggestion would be to add a fuzzy search option that can be turned on whenever needed.

Describe alternatives you've considered
If it's not the priority, do you mind telling me which file can change the search mode? I can try to see if I can add this function.

should you add a shortcut for it?

should you add a shortcut for save selection?
The popup icon cannot work. It maybe cause by my chrome.(I installed many popup icon function extensions).
Current, selection to save that just work right menu.
The right menu have many items, everytimes , I need to seek the "logseq-copilot" item in menu.
If you provide a shortcut for it. we can quickly call save function.
Thanks.

[QUESTION] chatGPT4Google

In the credits you mention chatGPT4Google. Does that mean chatGPT is only used when Google is the search engine?

Unable to clip selected text with Logseq 0.10.7 on Firefox

Describe the bug
I have enabled "Display floating button" and tried to select a text on a webpage and click on the floating button, but nothing gets captured. This used to work fine with earlier versions of both Logseq and the extension.

To Reproduce
Steps to reproduce the behavior:

  1. Select some text on a webpage (e.g. wikipedia)
  2. Click on the floating button to capture
  3. Should get captured in Logseq but nothing happens

Expected behavior
It should copy the text into the journal (or page, depending upon the setting)

Screenshots
Screenshot 2024-03-01 at 3 04 48 PM

Desktop (please complete the following information):

  • OS: MacOS
  • Browser: Firefox 123.0
  • Version: 1.14.1

Cannot work in some cases.

When I open many tabs in the chrome, after 5 mins or more,the copilot cannot work
( click or shortcut trigger the save action, the logseq has no add anything)
At this time , the copilot's setting show the connection is good.
i try to re-connect the logseq again, show message is connected.
But the webpage still cannot save content to logseq.
Need to refresh the page, ( in sometime, refresh also cannot work)

Performance issue

Describe the bug
After searching in google with logseq-copilot, logseq becomes more and more laggy with the passage of time.

To Reproduce
Steps to reproduce the behavior:

  1. Go to google
  2. Do some search.
  3. Back to logseq and use as usual. Keep logseq open.
  4. Input becomes more and more slow.

Desktop (please complete the following information):

  • OS:MacOS 13.2.1
  • Browser: chrome 111.0
  • Logseq: 0.8.18
  • Version 1.9.0

Badge is missing in Firefox

The extension icon's badge is missing in Firefox.

Debugging the extension shows this error:

Uncaught (in promise) TypeError: import_webextension_polyfill2.default.action is undefined
setExtensionBadge moz-extension://d7aec16b-630f-43c4-bd8c-f65d7dfc7020/background.js:8972
badgeSearch moz-extension://d7aec16b-630f-43c4-bd8c-f65d7dfc7020/background.js:10674

This is because Browser.action requires manifest v3 (https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/action), but for Firefox we use v2 (I suppose because Firefox doesn't support v3 background service worker?).

Possible solution:
Call Browser.browserAction instead (https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/API/browserAction)

"To block" link throwing error when opening in Logseq

Describe the bug
When I click on "To block" and try to open this in logseq, getting following error:
Screenshot 2024-01-08 at 3 03 25 PM

The full URL is: logseq://graph/?block-id=659bc102-9e4c-4892-925b-c473b9ce5911

Desktop (please complete the following information):

  • OS: MacOS Sonoma 14.2.1
  • Browser: Firefox 121.0
  • Logseq-copilot: 1.13.0

Unchecked runtime.lastError

Got this error with Chrome. Cannot write (clip) to Logseq, but the query works well.

I tried to reopen PC/chrome/logseq but all of them not work

OS:win10
Logseq:v0.9.13, v0.9.15

image

Render video in Graph out

Wow! I see YT tags render!

That's cool!

Is this intended behavior? How can I improve my markup to make this work?

1683827351222

Unable to clip unless the "Display Floating Button" is turned on

Describe the bug
A bug seems to have just developed for me starting today. I was unable to clip anything on both my work PC and my home PC. Logseq Copilot would show that it was connected to the API and would even show result in the google search results page but any attempt to clip a link would result in no errors but nothing would show up in Logseq. After playing around with things trying to find the issue I found out that I could resolve the issue and get it to clip if I turned on the "Display Floating Button" function. The weirder thing is that this also dosn't seem to actually show any floating button (something I didn't want anyways).

So this is solved for me, at least for now, as I'm getting the functionality that I'm looking for. But figured I would post the bug since it seems counter to expected results and in case it helps anyone else with the same issue.

To Reproduce
To cause the bug have "Display Floating Button" turned off, to apply the workaround turn it on.

Expected behavior
To have clipping function without the "Display Floating Button" turned on.

Desktop (please complete the following information):

  • OS: Windows 10 Pro
  • Browser: Chrome
  • Version: v1.14.1

links captured are displayed as [caption](url) rather than clickable caption

Discussed in #45

Originally posted by happy15 September 22, 2023
Take following part in https://blog.promaton.com/how-to-avoid-kpi-psychosis-in-your-organization-5ffc83967f2b as an example:

Just to give a glimpse: we take information that is easiest to gather (availability bias), often that is heavily affected by the latest info we got (recency bias) and when we make conclusions we tend to overgeneralize (halo/horn effect) with more confidence than it was justified by our lintels (overconfidence bias). On top, we are typically stubborn and seldom change our opinions and worldview (anchoring bias, confirmation bias). This is especially problematic when changes happen slowly and in small steps. For instance, the way software development productivity changes in our team.

When captured to logseq, the links are displayed as [caption](url), because they are escaped as \[availability bias]\(https://en.wikipedia.org/wiki/Availability_heuristic).

Any solution or workaround to this? Thanks.

Journale page used as dateformat, stops quickCapture from working

In this code the date format that is passed is the journalPage name. As it is August now, the first letter is A and this is not a valid character for date formatting.

Uncaught (in promise) RangeError: Format string contains an unescaped latin alphabet character `A`
    result moz-extension://7e84ec07-5a40-42f1-a0ae-62fdd0e916a8/background.js:5104
    format moz-extension://7e84ec07-5a40-42f1-a0ae-62fdd0e916a8/background.js:5085
    blockRending moz-extension://7e84ec07-5a40-42f1-a0ae-62fdd0e916a8/background.js:8548
    quickCapture moz-extension://7e84ec07-5a40-42f1-a0ae-62fdd0e916a8/background.js:8621
    async* moz-extension://7e84ec07-5a40-42f1-a0ae-62fdd0e916a8/background.js:8592

feat: support url hash at popup search

Discussed in #41

Originally posted by happy15 September 6, 2023
Hi there, I would like to discuss use cases like mine: the internal doc platform uses parts after # in the url to route to different docs.

For logseq copilot (which is awesome), it seems the parts after # is ignored when search logseq graph. For example, if I open some doc at sub.xxx.com/doc/#id=yyy, all url in the logseq graph which matches sub.xxx.com/doc/ will display in the plugin popup. They are actually different docs, so the search results in this use cases is not that useful.

Whether this due the design of logseq copilot plugin or logseq search api itself?

Results from Copilot not displaying when searching with Bing

Describe the bug
The cell shows up for Logseq-Copilot, including the link to the project web page and the feedback button, but none of the results of the search display inside the frame.

To Reproduce
Steps to reproduce the behavior:

  1. Go to bing.com
  2. Search for a text string you know exists in your Logseq graph
  3. View the Logseq-Copilot panel/sidebar
  4. See no results

Expected behavior
The Copilot sidebar should include relevant entries from the Logseq graph

Screenshots
Here's a screenshot from Bing showing the missing entries:
image
and here's the same search conducted in Google with the entries displayed correctly:
image

Desktop (please complete the following information):

  • OS: Windows 11
  • Browser: Edge Dev 117
  • Version: Logseq 0.9.13

Annotation Support

Since Copilot already supports webclipping, I'd like to make a feature request. Could you extend it to be more of a page clipper such that all annotations made on a certain page are saved under one Block eg
for url https://www.usatoday.com/story/tech/news/2023/08/09/google-will-begin-deleting-inactive-accounts-in-december/70560101007/

#[[Clip]] Google will begin deleting inactive accounts in December 2023

  • Annotation 1 from page
  • Annotation 2 from page
  • Annotation 3 and so on

Bonus features would be to

  1. Add a floating highlight button
  2. Highlighting the clipped text a certain color upon clipping.
  3. Re-highlight the clipped sections upon revisiting the page.

Use an indented block for the content in the Clip Template

Problem:
The default Clip Template pastes everything in one block inside Logseq.

Solution:
I would like to add the title in the first block, followed by an indented child block to make it foldable and more structured inside Logseg.

Example:
image

Alternative:
If this is already possible, it would be good to add it in the "available params" below the template window as a hint how to do it.

Sidenote
If I understand you right, than the following screenshot of the website describes this feature:
image

I propose a rewrite for more clarity. My suggestions:
Quick capture Send webpage info, including URL, title, and text selection to your Logseq graph.
Quick capture Save webpage info, including URL and title, to Logseq. Optionally, include the current text selection.

P.S.: Thanks for the work and effort you put into creating this plugin. 👏

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.