Skip to content

Commit dc3f98b

Browse files
Merge branch 'DEV' into code_cleanup_pre_DEV
2 parents 1dba6d4 + cf3fdba commit dc3f98b

File tree

6 files changed

+20
-11
lines changed

6 files changed

+20
-11
lines changed

backend/score.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ async def extract_knowledge_graph_from_file(
154154

155155

156156
else:
157-
return {"job_status": "Failure", "error": "No file found"}
157+
return {"status": "Failed", "error": "No file found"}
158158

159159

160160
@app.get("/sources_list")

backend/src/main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ def extract_graph_from_file(uri, userName, password, model, db_name=None, file=N
345345
"model" : model
346346
}
347347
logging.info(f'Response from extract API : {output}')
348-
return create_api_response("Success",data=output)
348+
return create_api_response("Success",data=output,file_name=file_name)
349349

350350
except Exception as e:
351351
job_status = "Failed"

frontend/src/components/Dropdown.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const LlmDropdown: React.FC<DropdownProps> = ({ onSelect, isDisabled }) => {
99
const allOptions = useMemo(() => ['Diffbot', 'OpenAI GPT 4'], []);
1010
return (
1111
<>
12-
<div style={{ width: '150px' }}>
12+
<div className='w-[150px]'>
1313
<Dropdown
1414
type='select'
1515
aria-label='A selection dropdown'

frontend/src/components/FileTable.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -146,10 +146,11 @@ const FileTable: React.FC<FileTableProps> = ({ isExpanded, connectionStatus, set
146146
if (!res.data) {
147147
throw new Error('Please check backend connection');
148148
}
149-
if (res.data.data.status !== 'Failed') {
149+
150+
if (res.data.status !== 'Failed') {
150151
const prefiles: CustomFile[] = [];
151-
if (res.data.data.data.length) {
152-
res.data.data.data.forEach((item: SourceNode) => {
152+
if (res.data.data.length) {
153+
res.data.data.forEach((item: SourceNode) => {
153154
if (item.fileName != undefined && item.fileName.length) {
154155
prefiles.push({
155156
name: item.fileName,

frontend/src/components/Layout/Header.tsx

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,18 @@ export default function Header({ themeMode, toggleTheme }: { themeMode: string;
2929
</section>
3030
<section className='items-center justify-end w-1/3 grow-0 flex'>
3131
<div>
32-
<div className='inline-flex gap-x-1 flex grow-0 items-center gap-1'>
33-
<Button href='https://github.com/neo4j-labs/llm-graph-builder/issues' fill='outlined' target='_blank'>
34-
Github Issues
35-
</Button>
32+
<div
33+
className='inline-flex gap-x-1'
34+
style={{ display: 'flex', flexGrow: 0, alignItems: 'center', gap: '4px' }}
35+
>
36+
<ButtonWithToolTip
37+
ishrefButton={true}
38+
href='https://github.com/neo4j-labs/llm-graph-builder/issues'
39+
target='_blank'
40+
text={'GitHub Issues'}
41+
>
42+
<CodeBracketIconOutline className='n-size-token-7' />
43+
</ButtonWithToolTip>
3644
<IconButton aria-label='Toggle Dark mode' clean size='large' onClick={toggleTheme}>
3745
{themeMode === 'dark' ? (
3846
<span role='img' aria-label='sun'>
@@ -47,7 +55,6 @@ export default function Header({ themeMode, toggleTheme }: { themeMode: string;
4755
<IconButton aria-label='Toggle settings' size='large' clean>
4856
<Cog8ToothIconOutline />
4957
</IconButton>
50-
5158
<Typography
5259
variant='subheading-large'
5360
style={{

frontend/src/components/WikipediaModal.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ const WikipediaModal: React.FC<WikipediaModalTypes> = ({ hideModal, open }) => {
6363
name: item.fileName,
6464
size: item.fileSize,
6565
wiki_query: item.fileName,
66+
source_url:item.url,
6667
...defaultValues,
6768
});
6869
} else {

0 commit comments

Comments
 (0)