nGene Regular Expression Builder

nGene Regular Expression Builder v 1.1 (b)

Compose

Sample text


  
How to use
  1. Open re.html in a modern browser.
  2. Type or paste a pattern, choose flags, and enter sample text.
  3. ISO‑date locator 🗓️

    1. Pattern: \b\d{4}-\d{2}-\d{2}\b
    2. Flag: g
    3. Sample :
    4. Agenda items due by 2025-05-12.
      Previous deadline was 1999-12-31.
  4. E‑mail extractor ✉️

    1. Pattern: [\w.+-]+@[\w.-]+\.[A-Za-z]{2,}
    2. Flag: gi
    3. Sample :
    4. Contact Support@nGene.org for assistance.
  5. Clipboard buttons 📋

    • Copy pattern – copies the field unchanged.
    • Copy escaped pattern – doubles back‑slashes (for code).
Token reference
TokenDescription
.Any character except newline
\dDigit 0‑9
\wWord character
\sWhitespace
[abc]a, b or c
[^abc]Not a, b or c
*0 or more
+1 or more
?0 or 1
{m,n}Range quantifier
^Start anchor
$End anchor
(…)Capturing group
(?:…)Non‑capturing group
|Alternation
Flag reference
FlagPurpose
gGlobal – find every match
iIgnore case
mMultiline anchors
sDotall – . matches newline
uUnicode mode
ySticky – start at lastIndex
Get an OpenAI API key
  1. Step 1 – Create / sign in
    Visit https://platform.openai.com/, sign up or log in, and complete any verification.
  2. Step 2 – Open API Keys
    Click your avatar (top‑right) → API Keys.
  3. Step 3 – Create key
    Press + Create new secret key, name it (e.g. “nGene regex”), click Create, then copy it immediately.
  4. Step 4 – Secure it
    Store the key safely (password manager / env var). Never commit it to public code.
    $ export OPENAI_API_KEY="sk-…"
    PS> setx OPENAI_API_KEY "sk-…"
  5. Step 5 – Verify
    Test with curl (or any SDK):
    curl https://api.openai.com/v1/models \
      -H "Authorization: Bearer $OPENAI_API_KEY"
    A JSON list of models confirms the key works.
Full Source Code (re.html)