-
+
@@ -93,20 +93,27 @@
{% block js %}
{% endblock %}
--
cgit 1.4.1
From 2c13a6224aa1fe7cd223a2c9cde237758ecfee7d Mon Sep 17 00:00:00 2001
From: Alexander_Kabui
Date: Mon, 2 Sep 2024 12:17:54 +0300
Subject: Run djlint for gnqa html files.
---
gn2/wqflask/templates/gnqa.html | 136 +++++++++---------
gn2/wqflask/templates/gnqa_answer.html | 243 +++++++++++++++++++++------------
2 files changed, 222 insertions(+), 157 deletions(-)
(limited to 'gn2/wqflask/templates/gnqa_answer.html')
diff --git a/gn2/wqflask/templates/gnqa.html b/gn2/wqflask/templates/gnqa.html
index b3bc74fd..6969bad9 100644
--- a/gn2/wqflask/templates/gnqa.html
+++ b/gn2/wqflask/templates/gnqa.html
@@ -1,9 +1,7 @@
{% extends "base.html" %}
{% block title %}GNQA{% endblock %}
-
{% block css %}
-
+
{% endblock %}
-
{% block search %}{% endblock %}
-{% block content %}
-
-
-
-
-
-
- Welcome to the GeneNetwork Question and Answer (GNQA)system. We utilize a large language model and 3000 scientific publications to make GNQA a subject matter expert in three areas: GeneNetwork.org , genomics/genetics with regards to diabetes and genomics/genetics with regards to agin. .
-
-
At the moment when you ask GNQA something it will attempt to return a sensible answer with real references. To this end we aim to reduce hallucinations and provide a knowledge launchpad for a researcher to enhance their knowledge on the relevant subject matter.
-
- GNQA is not a finished product as we are working diligently to improve it daily.
-
-
Thanks for using GNQA!
-
-
-
-
-
+{% block content %}
+
+
+
+
+
+
+
+ Welcome to the GeneNetwork Question and Answer (GNQA)system. We utilize a large language model and 3000 scientific publications to make GNQA a subject matter expert in three areas: GeneNetwork.org , genomics/genetics with regards to diabetes and genomics/genetics with regards to agin. .
+
+
+ At the moment when you ask GNQA something it will attempt to return a sensible answer with real references. To this end we aim to reduce hallucinations and provide a knowledge launchpad for a researcher to enhance their knowledge on the relevant subject matter.
+
+
+ GNQA is not a finished product as we are working diligently to improve it daily.
+
+
+ Thanks for using GNQA!
+
+
+
+
{% endblock %}
-
{% block js %}
-
-
-
-
-
-
-
+
+
+
+
{% endblock %}
-
diff --git a/gn2/wqflask/templates/gnqa_answer.html b/gn2/wqflask/templates/gnqa_answer.html
index 41c1b338..dc924d3b 100644
--- a/gn2/wqflask/templates/gnqa_answer.html
+++ b/gn2/wqflask/templates/gnqa_answer.html
@@ -1,98 +1,161 @@
-
-
- {{ query }}
- {{ answer|safe }}
-
-
-
-
-
-
-
+
+ {{ query }}
+
+ {{ answer|safe }}
+
+
+
+
+
+
+
+
+
+
+
-
- References
- {% if references %}
-
- {% for reference in references %}
-
-
-
- {% if loop.first %}
-
-
-
-
{{ reference.comboTxt|safe }}
-
- {% if reference.pubmed %}
-
- See PubMed Info
-
-
{{ reference.pubmed[0].get('title') }}:
-
Authors: {{ reference.pubmed[0].get('authors') }}
-
PMID: {{ reference.pubmed[0].get('pub_id') }}
-
Abstract:
-
{{ reference.pubmed[0].get('abstract')|safe }}
-
See full Article on Pubmed
-
-
- {% endif %}
-
-
- {% else %}
-
-
-
-
{{ reference.comboTxt|safe }}
-
- {% if reference.pubmed %}
-
- See PubMed Info
-
-
{{ reference.pubmed[0].get('title') }}:
-
Authors: {{ reference.pubmed[0].get('authors') }}
-
PMID: {{ reference.pubmed[0].get('pub_id') }}
-
Abstract:
-
{{ reference.pubmed[0].get('abstract')|safe }}
-
See full Article on Pubmed
-
-
- {% endif %}
-
-
-
- {% endif %}
-
-
-
- {% endfor %}
-
- {% else %}
-
No references available.
- {% endif %}
-
-
+
+
+ References
+
+ {% if references %}
+
+ {% for reference in references %}
+
+
+
+ {% if loop.first %}
+
+
+
+
{{ reference.comboTxt|safe }}
+
+ {% if reference.pubmed %}
+
+ See PubMed Info
+
+
+ {{ reference.pubmed[0].get("title") }}:
+
+
+ Authors: {{ reference.pubmed[0].get("authors") }}
+
+
+ PMID: {{ reference.pubmed[0].get("pub_id") }}
+
+
+ Abstract:
+
+
{{ reference.pubmed[0].get("abstract") |safe }}
+
+ See full Article on Pubmed
+
+
+
+ {% endif %}
+
+
+ {% else %}
+
+
+
+
{{ reference.comboTxt|safe }}
+
+ {% if reference.pubmed %}
+
+ See PubMed Info
+
+
+ {{ reference.pubmed[0].get("title") }}:
+
+
+ Authors: {{ reference.pubmed[0].get("authors") }}
+
+
+ PMID: {{ reference.pubmed[0].get("pub_id") }}
+
+
+ Abstract:
+
+
{{ reference.pubmed[0].get("abstract") |safe }}
+
+ See full Article on Pubmed
+
+
+
+ {% endif %}
+
+
+
+ {% endif %}
+
+
+
+ {% endfor %}
+
+ {% else %}
+
+ No references available.
+
+ {% endif %}
+
+
+
{% block js %}
-
-
+
{% endblock %}
--
cgit 1.4.1
From d82f8b31abb0e33c8d01f8906fd6a24d3b268de7 Mon Sep 17 00:00:00 2001
From: Alexander_Kabui
Date: Mon, 2 Sep 2024 12:44:59 +0300
Subject: Fix spacing for gnqa files.
---
gn2/wqflask/templates/gnqa_answer.html | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
(limited to 'gn2/wqflask/templates/gnqa_answer.html')
diff --git a/gn2/wqflask/templates/gnqa_answer.html b/gn2/wqflask/templates/gnqa_answer.html
index dc924d3b..6d976382 100644
--- a/gn2/wqflask/templates/gnqa_answer.html
+++ b/gn2/wqflask/templates/gnqa_answer.html
@@ -158,7 +158,7 @@
{% endblock %}
--
cgit 1.4.1
From f3843170bb0fe4cca17b529be61fc6ae438acfb6 Mon Sep 17 00:00:00 2001
From: Alexander_Kabui
Date: Mon, 2 Sep 2024 12:50:46 +0300
Subject: Span parameters across multiple lines for to improve readabity.
---
gn2/wqflask/templates/gnqa_answer.html | 13 +++++++++++--
1 file changed, 11 insertions(+), 2 deletions(-)
(limited to 'gn2/wqflask/templates/gnqa_answer.html')
diff --git a/gn2/wqflask/templates/gnqa_answer.html b/gn2/wqflask/templates/gnqa_answer.html
index 6d976382..7a637b20 100644
--- a/gn2/wqflask/templates/gnqa_answer.html
+++ b/gn2/wqflask/templates/gnqa_answer.html
@@ -174,9 +174,18 @@ var answer = {{ answer|tojson }}
var {task_id} = {{ task_id|tojson }}
htmx.on("#upvote", "click", function(evt){
vote_count = htmx.find(".btn-success") ? 0 : 1
- htmx.ajax("POST", `/gnqna/rating/${task_id}/${vote_count}`, {target: "#rate", handler: (target,obj)=> updateRatingHandler(target, obj, "upvote"), swap:"innerHTML",values: {'query': query, 'answer': answer}})});
+ htmx.ajax("POST",
+ `/gnqna/rating/${task_id}/${vote_count}`,
+ {target: "#rate",
+ handler: (target,obj)=> updateRatingHandler(target, obj, "upvote"),
+ swap:"innerHTML",
+ values: {'query': query, 'answer': answer}})});
htmx.on("#downvote", "click", function(evt){
vote_count = htmx.find(".btn-danger") ? 0 : -1
- htmx.ajax("POST", `/gnqna/rating/${task_id}/${vote_count}`, {target: "#rate",handler: (target,obj)=> updateRatingHandler(target,obj, "downvote") , swap:"innerHTML",values: {'query': query, 'answer': answer}})});
+ htmx.ajax("POST", `/gnqna/rating/${task_id}/${vote_count}`,
+ {target: "#rate",
+ handler: (target, obj)=> updateRatingHandler(target,obj, "downvote"),
+ swap:"innerHTML",
+ values: {'query': query, 'answer': answer}})});
{% endblock %}
--
cgit 1.4.1