cdancy commited on
Commit
9d9ca20
1 Parent(s): 1965bb4

Small mods towards working demo

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
app.py CHANGED
@@ -12,25 +12,18 @@ DEFAULT_MAX_NEW_TOKENS = 1024
12
  MAX_INPUT_TOKEN_LENGTH = int(os.getenv("MAX_INPUT_TOKEN_LENGTH", "4096"))
13
 
14
  DESCRIPTION = """\
15
- # Llama-2 7B Chat
16
 
17
- This Space demonstrates model [Llama-2-7b-chat](https://huggingface.co/meta-llama/Llama-2-7b-chat) by Meta, a Llama 2 model with 7B parameters fine-tuned for chat instructions. Feel free to play with it, or duplicate to run generations without a queue! If you want to run your own service, you can also [deploy the model on Inference Endpoints](https://huggingface.co/inference-endpoints).
18
-
19
- 🔎 For more details about the Llama 2 family of models and how to use them with `transformers`, take a look [at our blog post](https://huggingface.co/blog/llama2).
20
-
21
- 🔨 Looking for an even more powerful model? Check out the [13B version](https://huggingface.co/spaces/huggingface-projects/llama-2-13b-chat) or the large [70B model demo](https://huggingface.co/spaces/ysharma/Explore_llamav2_with_TGI).
22
  """
23
 
24
  LICENSE = """
25
  <p/>
26
 
27
- ---
28
- As a derivate work of [Llama-2-7b-chat](https://huggingface.co/meta-llama/Llama-2-7b-chat) by Meta,
29
- this demo is governed by the original [license](https://huggingface.co/spaces/huggingface-projects/llama-2-7b-chat/blob/main/LICENSE.txt) and [acceptable use policy](https://huggingface.co/spaces/huggingface-projects/llama-2-7b-chat/blob/main/USE_POLICY.md).
30
  """
31
 
32
  if not torch.cuda.is_available():
33
- DESCRIPTION += "\n<p>Running on CPU 🥶 This demo does not work on CPU.</p>"
34
 
35
 
36
  if torch.cuda.is_available():
@@ -127,19 +120,18 @@ chat_interface = gr.ChatInterface(
127
  ],
128
  stop_btn=None,
129
  examples=[
130
- ["Hello there! How are you doing?"],
131
  ["Can you explain briefly to me what is the Python programming language?"],
132
  ["Explain the plot of Cinderella in a sentence."],
133
  ["How many hours does it take a man to eat a Helicopter?"],
134
- ["Write a 100-word article on 'Benefits of Open-Source in AI research'"],
135
  ],
136
  )
137
 
138
- with gr.Blocks(css="style.css") as demo:
139
  gr.Markdown(DESCRIPTION)
140
- gr.DuplicateButton(value="Duplicate Space for private use", elem_id="duplicate-button")
141
  chat_interface.render()
142
  gr.Markdown(LICENSE)
143
 
144
  if __name__ == "__main__":
145
- demo.queue(max_size=20).launch()
 
12
  MAX_INPUT_TOKEN_LENGTH = int(os.getenv("MAX_INPUT_TOKEN_LENGTH", "4096"))
13
 
14
  DESCRIPTION = """\
15
+ # Test Chat Information System for MEPO Summer Bridge 2024 courtesy of Dr. Dancy & THiCC Lab
16
 
17
+ Duplicated then modified from [llama-2 7B example](https://huggingface.co/meta-llama/Llama-2-7b-chat)
 
 
 
 
18
  """
19
 
20
  LICENSE = """
21
  <p/>
22
 
 
 
 
23
  """
24
 
25
  if not torch.cuda.is_available():
26
+ DESCRIPTION += "We won't be able to run this space! We need GPU processing"
27
 
28
 
29
  if torch.cuda.is_available():
 
120
  ],
121
  stop_btn=None,
122
  examples=[
123
+ [["Hello there! How are you doing?"],
124
  ["Can you explain briefly to me what is the Python programming language?"],
125
  ["Explain the plot of Cinderella in a sentence."],
126
  ["How many hours does it take a man to eat a Helicopter?"],
127
+ ["Write a 100-word article on 'Benefits of Open-Source in AI research'"]],
128
  ],
129
  )
130
 
131
+ with gr.Blocks(css="style.css") as chat_interface:
132
  gr.Markdown(DESCRIPTION)
 
133
  chat_interface.render()
134
  gr.Markdown(LICENSE)
135
 
136
  if __name__ == "__main__":
137
+ chat_interface.queue(max_size=20).launch()
bin ADDED
@@ -0,0 +1 @@
 
 
1
+ usr/bin
dev/block/1:0 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram0
dev/block/1:1 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram1
dev/block/1:10 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram10
dev/block/1:11 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram11
dev/block/1:12 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram12
dev/block/1:13 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram13
dev/block/1:14 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram14
dev/block/1:15 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram15
dev/block/1:2 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram2
dev/block/1:3 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram3
dev/block/1:4 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram4
dev/block/1:5 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram5
dev/block/1:6 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram6
dev/block/1:7 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram7
dev/block/1:8 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram8
dev/block/1:9 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ram9
dev/block/7:0 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../loop0
dev/block/7:1 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../loop1
dev/block/7:2 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../loop2
dev/block/7:3 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../loop3
dev/block/7:4 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../loop4
dev/block/7:5 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../loop5
dev/block/7:6 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../loop6
dev/block/7:7 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../loop7
dev/block/8:0 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../sda
dev/block/8:16 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../sdb
dev/block/8:32 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../sdc
dev/char/108:0 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../ppp
dev/char/10:125 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../cpu_dma_latency
dev/char/10:126 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../vsock
dev/char/10:127 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../dxg
dev/char/10:144 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../nvram
dev/char/10:196 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../vfio/vfio
dev/char/10:200 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../net/tun
dev/char/10:203 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../cuse
dev/char/10:229 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../fuse
dev/char/10:232 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../kvm
dev/char/10:234 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../btrfs-control
dev/char/10:235 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../autofs
dev/char/10:236 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../mapper/control
dev/char/10:237 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../loop-control
dev/char/10:238 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../vhost-net
dev/char/189:0 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../bus/usb/001/001
dev/char/189:128 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../bus/usb/002/001
dev/char/1:1 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../mem
dev/char/1:11 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../kmsg
dev/char/1:3 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../null
dev/char/1:5 ADDED
@@ -0,0 +1 @@
 
 
1
+ ../zero