From 4c6f750e520904908cd9ad6b9b700176799324a0 Mon Sep 17 00:00:00 2001 From: Fraser Date: Mon, 10 Jul 2023 20:39:54 -0400 Subject: [PATCH 1/2] link to duckduckgo when url field empty --- web/src/pages/index.tsx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/web/src/pages/index.tsx b/web/src/pages/index.tsx index edce828..143d0cf 100644 --- a/web/src/pages/index.tsx +++ b/web/src/pages/index.tsx @@ -72,9 +72,14 @@ const ShowCitation: React.FC<{citation: Citation, i: number}> = ({citation, i}) if (citation.date && citation.date !== "") c_str += " - " + citation.date; + // if we don't have a url, link to a duckduckgo search for the title instead + const url = citation.url && citation.url !== "" + ? citation.url + : `https://duckduckgo.com/?q=${encodeURIComponent(citation.title)}`; + return ( + href={url}> [{i + 1}]

{c_str}

From 64a48c63062ed1f9bed51471428c24838225ad52 Mon Sep 17 00:00:00 2001 From: ccstan99 Date: Tue, 11 Jul 2023 18:02:26 -0700 Subject: [PATCH 2/2] update header, ard-private readme --- readme.md | 15 ++++++++------- web/src/header.tsx | 11 ++++++----- web/src/pages/index.tsx | 4 +++- web/src/pages/semantic.tsx | 4 ++-- 4 files changed, 19 insertions(+), 15 deletions(-) diff --git a/readme.md b/readme.md index 05d8b65..64c65e1 100644 --- a/readme.md +++ b/readme.md @@ -23,9 +23,6 @@ In general, the Stampy project serves users at 3 levels of understanding: Given the disparate backgrounds of users, for both the website and chatbot, we should consider having users identify their starting level (new, moderate, knowledgeable). On the website, the list of starter and recommended questions would be tuned to the user’s level. Similarly, the chatbot's usage of technical terminology could be adjusted to their level. - - - ## Usage ### Environment Setup @@ -58,10 +55,14 @@ npm run dev In the second window, a URL will be printed. Probably `http://localhost:3000`. Paste this into your browser to see the app. +### Accessing Dataset - - - +If you'll be loading data alignment research dataset to be embedded and stored in pinecone, +you'll need to access to our [private version of the dataset](https://huggingface.co/datasets/StampyAI/ard-private). +1. Create a free [HuggingFace account](https://huggingface.co/join). +2. Give admin your account name to be added to the organization. DM ccstan on Discord. +3. Create an [access token](https://huggingface.co/settings/tokens). +4. Follow [login instructions](https://huggingface.co/docs/huggingface_hub/quick-start) to access private datasets. ## Original Prototypes @@ -70,6 +71,6 @@ The teams collaborated and key features were combined into one project. Name | Demo App | Code Notes -- | -- | -- -McGill's AlignmentSearch | https://alignmentsearch.up.railway.app/ | https://github.com/FraserLee/AlignmentSearch
https://tinyurl.com/alignmentsearchgdocs +McGill's AlignmentSearch | https://alignmentsearch.up.railway.app/ | https://github.com/FraserLee/AlignmentSearch
https://www.lesswrong.com/posts/bGn9ZjeuJCg7HkKBj/introducing-alignmentsearch-an-ai-alignment-informed Craig's AlignmentGPT | http://tidblitz.com/ | https://github.com/cvarrichio/alignmentchat Stampy's Chat | http://chat.stampy.ai/ | https://github.com/ccstan99/stampy-chat
https://github.com/stampyAI/stampy-nlp/ diff --git a/web/src/header.tsx b/web/src/header.tsx index bbcc0c3..3281f15 100644 --- a/web/src/header.tsx +++ b/web/src/header.tsx @@ -1,22 +1,23 @@ import React from "react"; import Link from "next/link"; +import Image from 'next/image'; +import logo from "./logo.svg" const Header: React.FC<{page: "index" | "semantic"}> = ({page}) => { const sidebar = page === "index" ? ( -

Conversational Agent

- Semantic Search + Show Sources
) : ( - Conversational Agent -

Semantic Search

+ Go Chat
); return (<>
-

AlignmentSearch

+ aisafety.info logo +

AI Safety Chatbot

{sidebar}
); diff --git a/web/src/pages/index.tsx b/web/src/pages/index.tsx index 143d0cf..1a0a168 100644 --- a/web/src/pages/index.tsx +++ b/web/src/pages/index.tsx @@ -4,6 +4,7 @@ import Head from "next/head"; import React from "react"; import { type NextPage } from "next"; import { useState } from "react"; +import Link from "next/link"; import Image from 'next/image'; import Header from "../header"; @@ -462,10 +463,11 @@ const Home: NextPage = () => { return ( <> - Alignment Search + AI Safety Info
+

WARNING: This is a very early prototype using data through June 2022. Feedback welcomed.

    {entries.map((entry, i) => { diff --git a/web/src/pages/semantic.tsx b/web/src/pages/semantic.tsx index a344ee2..45dd77c 100644 --- a/web/src/pages/semantic.tsx +++ b/web/src/pages/semantic.tsx @@ -41,11 +41,11 @@ const Semantic: NextPage = () => { return ( <> - Alignment Search + AI Safety Info
    -

    See the raw results of a semantic search

    +

    Retrieve relevant data sources from alignment research

      {results.map((entry, i) => (