corvo7 commited on
Commit
0c2245b
·
verified ·
1 Parent(s): a2a9547

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +39 -5
app.py CHANGED
@@ -24,8 +24,42 @@ So AI field is giving us three tools and technqiues they are
24
  2) DL (Deep Learning)
25
  3) Gen-AI (Generative AI)""")
26
 
27
- st.markdown("""So by using the above three tools we can mimic/copy the learning and thinking skills of human beign to machine .So they also can
28
- Learn and generate from the data""")
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
29
 
30
  if st.button("Answer from gpt"):
31
  responds=openai.chat.completions.create(
@@ -34,10 +68,10 @@ if st.button("Answer from gpt"):
34
  {"role": "system", "content": "you are a very good assistant"},# set the behaviour of
35
  {"role": "user", "content": "What do we mean by ai"}
36
  ],
37
- temperature=0,
38
- max_tokens=200
39
 
40
  )
41
  st.write(responds.choices[0].message.content)
42
  else:
43
- st.write("thx")
 
24
  2) DL (Deep Learning)
25
  3) Gen-AI (Generative AI)""")
26
 
27
+ st.markdown("""So by using the above three tools we can mimic/copy the learning and thinking skills of human beign to machine .So that they also can
28
+ Learn and Generate from the data""")
29
+ if st.button("Click to know more about What is Data "):
30
+ responds=openai.chat.completions.create(
31
+ model="gpt-3.5-turbo",
32
+ messages=[
33
+ {"role": "system", "content": "you are a very good assistant"},# set the behaviour of
34
+ {"role": "user", "content": "What is Data in machine learningn and deep learning"}
35
+ ],
36
+ temperature=0.5,
37
+ max_tokens=500
38
+
39
+ )
40
+ st.write(responds.choices[0].message.content)
41
+
42
+
43
+ st.markdown("""So now let's talk about how to make machine mimic learning skills from Data""")
44
+ st.markdown("""So we human beigns learn's from our experinece.But machine requires data to learn from.""")
45
+ st.markdown("""Here what is machine learning,machine's is here is trying to learn the actual realtionship between
46
+ the input features and the output classes from the data.""")
47
+ st.markdown("""Mathematically its nothing but the below formula""")
48
+ st.markdown(""" y=f(x)""")
49
+ st.markdown(""" where y is the output variable(classes) and x is the feature variable (features) and f is the learned relationship between x and y""")
50
+
51
+ if st.button("Example "):
52
+ responds=openai.chat.completions.create(
53
+ model="gpt-3.5-turbo",
54
+ messages=[
55
+ {"role": "system", "content": "you are a very good assistant"},# set the behaviour of
56
+ {"role": "user", "content": "Give an simple example based on y=f(x) in ml or dl"}
57
+ ],
58
+ temperature=0.5,
59
+ max_tokens=500
60
+
61
+ )
62
+ st.write(responds.choices[0].message.content)
63
 
64
  if st.button("Answer from gpt"):
65
  responds=openai.chat.completions.create(
 
68
  {"role": "system", "content": "you are a very good assistant"},# set the behaviour of
69
  {"role": "user", "content": "What do we mean by ai"}
70
  ],
71
+ temperature=0.5,
72
+ max_tokens=500
73
 
74
  )
75
  st.write(responds.choices[0].message.content)
76
  else:
77
+ st.write(" ")