Code Monkey home page Code Monkey logo

copyequation's Introduction

Information

This extension allows you to copy equations from ChatGPT and Wikipedia into Word (aka. the MathML format) and as LaTeX. It supports both the white and dark mode of the ChatGPT GUI and the Darkreader extension for the Wikipedia website (and the ChatGPT one if you're really into that). If you wanna use multiline pasting into MS Word, you can only do this on Windows using the PasteEquation Extension (and having this extension installed as well of course).

Installation

If you're using Firefox visit https://addons.mozilla.org/addon/copyequation/. It also works for the Android version of Firefox which is the only mobile version this extension supports. For desktop Chromium-based browsers follow these steps to download and install the extension:

Step 1: Clone the Repository

Open your terminal and run the following command to clone the repository:

git clone https://github.com/Foxxey/ChatGPT-LaTeX-MathML-Copy.git

Step 2: Navigate to the Extension Page

Open your Chromium-based browser (Chrome, Edge, Brave etc.) and go to the extensions page by entering the following URL in the address bar:

chrome://extensions

Make sure the "Developer mode" is turned on.

Step 3: Load the Extension

Click on the "Load unpacked" button and select the directory where you cloned the repository. This will load the extension into your browser.

How to Use

After installing the extension, visit ChatGPT or Wikipedia. When you see a mathematical expression, right-click on it. You should see an option to copy either the LaTeX or Word/MathML data. Alternatively you can click on one of the icons next to where it says "ChatGPT" to copy a whole message with the equations (Word/MathML for this "multiline" option only works on Windows using a MS Word Extension). Now you can paste it into Word or your favorite TeX distribution. Have fun!

HowTo

If you encounter any issues or have suggestions, feel free to contribute by submitting a pull request. If you do please update the manifest.json by adding 1 to the minor version.

copyequation's People

Contributors

foxxey avatar

Stargazers

 avatar Igor avatar  avatar Dennis 'Lucius' Chimezie avatar Xiangyu Pan avatar  avatar Javad Razi avatar Behnam Sa avatar Ares avatar  avatar  avatar  avatar Martin Timms avatar Muhammad Farhan Pulungan avatar Vaishnav Varma avatar  avatar mnnaegel avatar Qingtao Chen avatar miaoj365 avatar yuliu avatar  avatar  avatar Komal Bakshi avatar  avatar Jiatong Han avatar Qiyang Gao avatar PiaoYang avatar Qi avatar  avatar  avatar Muhammad Irfani avatar

Watchers

Behnam Sa avatar  avatar  avatar

copyequation's Issues

Can't copy Cross Entropy formula in Word

Hi, when I try to copy the cross entropy function in Word instead of the formula I get this:
<math xmlns="http://www.w3.org/1998/Math/MathML"><semantics><mrow><mtext>Cross&nbsp;Entropy</mtext><mo>=</mo><mo>−</mo><mfrac><mn>1</mn><mi>n</mi></mfrac><msubsup><mo>∑</mo><mrow><mi>i</mi><mo>=</mo><mn>1</mn></mrow><mi>n</mi></msubsup><mrow><mo fence="true">[</mo><msub><mi>y</mi><mi>i</mi></msub><mi>log</mi><mo>⁡</mo><mo stretchy="false">(</mo><msub><mover accent="true"><mi>y</mi><mo>^</mo></mover><mi>i</mi></msub><mo stretchy="false">)</mo><mo>+</mo><mo stretchy="false">(</mo><mn>1</mn><mo>−</mo><msub><mi>y</mi><mi>i</mi></msub><mo stretchy="false">)</mo><mi>log</mi><mo>⁡</mo><mo stretchy="false">(</mo><mn>1</mn><mo>−</mo><msub><mover accent="true"><mi>y</mi><mo>^</mo></mover><mi>i</mi></msub><mo stretchy="false">)</mo><mo fence="true">]</mo></mrow></mrow><annotation encoding="application/x-tex">\text{Cross Entropy} = -\frac{1}{n} \sum_{i=1}^{n} \left[ y_i \log(\hat{y}_i) + (1 - y_i) \log(1 - \hat{y}_i) \right]</annotation></semantics></math>

Probably the addon doesn't parse well the code given by ChatGPT, that is:
\[ \text{Cross Entropy} = -\frac{1}{n} \sum_{i=1}^{n} \left[ y_i \log(\hat{y}_i) + (1 - y_i) \log(1 - \hat{y}_i) \right] \]

A small suggestion

This feature is really great. Perhaps you can promote it and also adapt its features in Claude and Poe. Nowadays, these web pages may be used more frequently by people.

Issue with new interface of ChatGPT

The new interface of ChatGPT no longer has a button to copy the whole response with all the equations formatted the right way. The button next the ChatGPT name which let us copy the whole response is not there anymore.

image

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.