Download example_output.md from bstraehle/multi-agent-ai-microsoft-coding: direct link, hf CLI and curl.
- Browser
- Download file 387 kB
-
https://huggingface.co/spaces/bstraehle/multi-agent-ai-microsoft-coding/resolve/main/example_output.md
- Command line
-
hf download hf://spaces/bstraehle/multi-agent-ai-microsoft-coding/example_output.md
-
curl -L -o example_output.md https://huggingface.co/spaces/bstraehle/multi-agent-ai-microsoft-coding/resolve/main/example_output.md
Code Writer called today({})
Code Writer called yf_download({"tickers":["NVDA","MSFT","AAPL","GOOG"],"start_date":"2025-12-31","end_date":"2026-11-22"})
Code Writer (code interpreter)
import os
print(os.listdir('/mnt/data'))
Code Writer (code interpreter)
from pathlib import Path
# Closing-price columns from the Yahoo Finance download, rounded to $0.001.
data = """Date,AAPL,GOOG,MSFT,NVDA
2025-12-31,270.916,313.187,479.645,186.065
2026-01-02,270.069,314.704,469.052,188.409
2026-01-05,266.332,316.700,468.963,187.681
2026-01-06,261.449,313.936,474.577,186.803
2026-01-07,259.426,321.800,479.496,188.669
2026-01-08,258.141,325.373,474.180,184.608
2026-01-09,258.470,328.497,475.340,184.428
2026-01-12,259.346,332.080,473.258,184.508
2026-01-13,260.144,335.773,466.801,185.376
2026-01-14,259.057,335.653,455.604,182.712
2026-01-15,257.314,332.509,452.906,186.613
2026-01-16,254.643,329.695,456.080,185.795
2026-01-20,245.844,321.531,450.784,177.654
2026-01-21,246.790,327.739,440.459,182.892
2026-01-22,247.488,330.194,447.432,184.408
2026-01-23,247.179,327.789,462.120,187.232
2026-01-26,254.523,332.939,466.414,186.035
2026-01-27,257.373,334.346,476.630,188.080
2026-01-28,255.550,335.623,477.671,191.073
2026-01-29,257.383,337.999,429.937,192.061
2026-01-30,258.579,337.869,426.753,190.684
2026-02-02,269.073,344.226,419.890,185.177
2026-02-03,268.544,340.035,407.830,179.919
2026-02-04,275.530,332.689,410.785,173.783
2026-02-05,274.952,330.683,390.434,171.479
2026-02-06,277.154,322.469,397.843,184.977
2026-02-09,273.923,323.766,410.200,189.596
2026-02-10,272.985,318.008,409.873,188.100
2026-02-11,274.800,310.722,401.046,189.606
2026-02-12,261.065,308.766,398.537,186.504
2026-02-13,255.131,305.422,398.021,182.383
2026-02-17,263.210,302.229,393.598,184.538
2026-02-18,263.679,303.346,396.315,187.541
2026-02-19,259.918,302.967,396.087,187.461
2026-02-20,263.908,314.285,394.864,189.377
2026-02-23,265.504,311.081,382.180,191.103
2026-02-24,271.449,310.313,386.683,192.400
2026-02-25,273.534,312.419,398.214,195.103
2026-02-26,272.257,306.550,399.327,184.458
2026-02-27,263.509,310.822,390.401,176.776
2026-03-02,264.048,305.762,396.176,182.054
2026-03-03,263.080,302.967,401.524,179.630
2026-03-04,261.853,302.857,402.786,182.613
2026-03-05,259.629,300.322,408.234,182.912
2026-03-06,256.806,297.717,406.524,177.405
2026-03-09,259.220,305.628,406.971,182.224
2026-03-10,260.168,306.546,403.343,184.339
2026-03-11,260.148,308.035,402.468,185.606
2026-03-12,255.111,302.831,399.466,182.722
2026-03-13,249.485,301.083,393.194,179.839
2026-03-16,252.178,304.040,397.568,182.802
2026-03-17,253.584,309.023,397.031,181.515
2026-03-18,249.305,305.917,389.456,179.989
2026-03-19,248.328,305.348,386.703,178.153
2026-03-20,247.360,298.417,379.595,172.306
2026-03-23,250.851,298.646,380.719,175.239
2026-03-24,251.001,288.839,370.520,174.800
2026-03-25,251.979,289.228,368.830,178.273
2026-03-26,252.248,280.389,363.790,170.849
2026-03-27,248.168,273.418,354.645,167.138
2026-03-30,246.004,272.799,356.822,164.793
2026-03-31,253.146,286.501,367.965,174.002
2026-04-01,254.981,294.531,367.170,175.349
2026-04-02,255.270,294.092,371.236,176.985
2026-04-06,258.203,297.288,370.659,177.235
2026-04-07,252.856,303.550,370.073,177.694
2026-04-08,258.243,314.347,372.100,181.665
2026-04-09,259.829,315.975,370.848,183.491
2026-04-10,259.819,315.325,368.661,188.200
2026-04-13,258.542,318.811,382.081,188.878
2026-04-14,258.173,330.167,390.768,196.062
2026-04-15,265.753,334.052,408.771,198.416
2026-04-16,262.731,332.354,417.757,197.898
2026-04-17,269.544,338.976,420.272,201.220
2026-04-20,272.357,334.981,415.580,201.599
2026-04-21,265.494,330.057,421.634,199.424
2026-04-22,272.476,337.308,430.341,202.038
2026-04-23,272.736,337.328,413.274,199.185
2026-04-24,270.372,341.892,422.091,207.795
2026-04-27,266.930,348.084,422.290,216.116
2026-04-28,270.023,347.066,426.693,212.684
2026-04-29,269.484,346.876,421.932,208.773
2026-04-30,270.661,381.463,405.351,199.115
2026-05-01,279.429,382.741,411.971,197.997
2026-05-04,276.127,379.166,411.156,198.027
2026-05-05,283.458,383.790,408.930,196.052
2026-05-06,286.780,394.646,411.494,207.356
2026-05-07,286.710,394.806,418.264,211.018
2026-05-08,292.575,396.554,412.647,214.709
2026-05-11,292.206,386.287,410.202,218.940
2026-05-12,294.322,383.340,405.341,220.277
2026-05-13,298.386,398.541,402.796,225.315
2026-05-14,297.727,396.674,406.991,235.202
2026-05-15,299.744,392.828,419.407,224.806
2026-05-18,297.357,392.619,421.017,221.813
2026-05-19,298.486,384.419,414.934,220.107
2026-05-20,301.760,384.419,418.552,222.960
2026-05-21,304.496,382.991,417.496,219.009
2026-05-22,308.320,378.906,416.978,214.839
2026-05-26,307.830,384.359,414.448,214.370
2026-05-27,310.346,384.349,411.100,212.115
2026-05-28,312.004,385.637,425.366,213.761
2026-05-29,311.554,375.960,448.528,210.658
2026-06-01,305.814,372.114,458.768,223.848
2026-06-02,314.689,357.942,439.632,222.312
2026-06-03,309.757,355.235,425.715,214.260
2026-06-04,310.726,368.808,426.422,218.416
2026-06-05,306.842,365.303,415.085,204.871
2026-06-08,301.051,360.936,410.174,208.407
2026-06-09,290.079,362.055,401.876,207.957
2026-06-10,291.108,353.091,395.849,200.196
2026-06-11,295.151,356.329,388.855,204.641
2026-06-12,290.658,357.928,389.254,204.961
2026-06-15,295.940,366.872,398.240,212.213
2026-06-16,298.755,370.859,392.332,207.178
2026-06-17,295.470,361.865,377.469,204.421
2026-06-18,297.527,367.222,377.957,210.455
2026-06-22,296.529,348.554,365.943,208.417
2026-06-23,293.823,345.855,372.518,199.816
2026-06-24,292.605,344.816,364.070,198.778
2026-06-25,274.704,341.968,351.488,195.521
2026-06-26,283.320,334.473,371.551,192.315
2026-06-29,281.284,351.052,367.168,194.752
2026-06-30,288.891,353.101,371.601,199.866
2026-07-01,293.903,357.658,382.818,197.359
2026-07-02,308.130,355.949,389.005,194.612
2026-07-06,312.153,364.663,385.269,195.331
2026-07-07,310.157,363.384,387.361,196.710
2026-07-08,312.882,358.477,381.882,203.892
2026-07-09,315.708,356.009,382.898,202.553
2026-07-10,314.809,354.800,383.635,210.724
2026-07-13,316.796,350.443,389.503,203.303
2026-07-14,314.350,357.098,383.466,211.563
2026-07-15,326.969,369.970,394.125,212.262
2026-07-16,332.720,353.580,399.574,207.168
2026-07-17,333.199,345.895,392.322,202.583
2026-07-20,326.061,351.142,400.760,203.053
2026-07-21,327.209,345.965,396.237,207.058
2026-07-22,325.362,341.688,388.855,211.823
2026-07-23,321.139,318.133,380.129,208.527
2026-07-24,332.480,318.883,380.248,206.609
2026-07-27,336.364,326.358,387.620,196.290
2026-07-28,339.529,332.384,391.854,196.790
2026-07-29,337.642,335.542,389.055,189.798
2026-07-30,332.890,333.464,449.384,194.822
2026-07-31,308.409,356.419,462.952,200.526
2026-08-03,302.928,372.228,485.795,206.409
2026-08-04,308.879,375.106,490.936,211.703
2026-08-05,310.496,359.896,485.606,218.975
2026-08-06,311.904,356.389,497.959,218.745
2026-08-07,312.822,353.241,498.088,223.710
2026-08-10,308.026,355.609,504.135,217.307
2026-08-11,304.678,342.777,501.894,217.257
2026-08-12,302.021,342.148,490.557,223.840
2026-08-13,305.028,343.717,494.990,225.048
2026-08-14,305.698,343.317,493.516,224.908
2026-08-17,305.358,341.228,478.523,224.758
2026-08-18,309.795,341.059,479.798,219.494
2026-08-19,316.589,341.478,482.468,217.317
2026-08-20,311.064,337.981,480.222,216.608
2026-08-21,309.115,341.528,482.308,214.480
2026-08-24,310.104,344.366,486.370,208.247
2026-08-25,309.665,343.117,490.762,212.812
2026-08-26,313.212,338.880,495.413,209.426
2026-08-27,314.341,337.491,504.086,227.725
2026-08-28,319.457,342.658,512.540,217.307
2026-08-31,316.609,335.192,506.312,220.533
2026-09-01,324.883,331.815,500.054,217.197
2026-09-02,324.713,333.563,495.862,224.159
2026-09-03,327.961,338.860,509.136,228.195
2026-09-04,319.727,335.310,498.737,230.103
2026-09-08,315.980,335.380,492.998,225.478
2026-09-09,315.101,328.380,490.702,223.420
2026-09-10,326.322,330.390,491.491,218.360
2026-09-11,332.018,335.450,494.674,218.290
2026-09-14,332.827,345.710,504.436,210.960
2026-09-15,331.088,341.430,496.162,212.170
2026-09-16,332.158,339.360,489.355,213.900
2026-09-17,336.744,343.680,496.790,219.340
2026-09-18,335.875,344.410,492.828,222.270
2026-09-21,338.723,350.870,500.643,227.380
2026-09-22,339.492,347.410,497.040,228.870
2026-09-23,336.764,334.980,499.625,225.510
2026-09-24,335.665,339.010,496.970,224.580
2026-09-25,340.811,341.080,515.175,225.070
2026-09-28,338.143,339.160,508.238,228.860
2026-09-29,329.150,337.320,507.979,227.210
2026-09-30,332.767,340.740,511.911,228.380
2026-10-01,330.069,334.930,511.811,230.860
2026-10-02,333.437,340.350,516.532,233.950
2026-10-05,332.637,343.830,524.167,238.900
2026-10-06,333.377,344.590,528.279,239.240
2026-10-07,336.414,347.370,528.739,237.470
2026-10-08,340.162,344.860,521.602,230.480
2026-10-09,336.384,347.860,534.038,229.280
2026-10-12,340.711,348.970,540.107,226.320
2026-10-13,341.011,349.520,542.402,228.520
2026-10-14,342.700,343.650,532.661,221.300
2026-10-15,341.740,344.910,538.400,217.230
2026-10-16,343.199,336.910,528.030,214.130
2026-10-19,342.680,340.160,532.491,217.090
2026-10-20,339.242,336.400,530.845,216.470
2026-10-21,343.729,330.950,531.922,221.970
2026-10-22,347.956,320.760,520.075,212.210
2026-10-23,347.466,317.280,523.499,210.960
2026-10-26,343.649,314.190,531.573,216.000
2026-10-27,346.836,316.830,530.306,217.940
2026-10-28,343.569,321.890,529.986,215.380
2026-10-29,348.645,282.320,529.118,213.660
2026-10-30,344.368,278.220,520.904,204.640
2026-11-02,338.063,278.040,506.142,202.060
2026-11-03,331.648,278.270,519.986,206.690
2026-11-04,349.245,287.300,554.728,200.130
2026-11-05,343.909,281.740,534.897,181.600
2026-11-06,342.110,283.930,529.587,186.640
2026-11-09,350.424,286.010,544.129,178.670
2026-11-10,348.245,284.920,532.132,168.890
2026-11-11,355.360,290.630,520.125,173.730
2026-11-12,354.880,295.350,521.992,166.190
2026-11-13,356.270,292.520,522.870,162.850
2026-11-16,352.780,281.260,516.991,156.140
2026-11-17,351.910,277.600,505.264,155.460
2026-11-18,352.450,279.200,507.310,150.960
2026-11-19,349.210,271.020,498.300,145.980
2026-11-20,342.560,264.000,484.520,125.530
"""
directory = Path("/mnt/data")
_ = (directory / "yahoo_finance_closes.csv").write_text(data, encoding="utf-8")
Code Writer (code interpreter)
"""Plot daily 2026 year-to-date stock gains using Yahoo Finance closing prices."""
from pathlib import Path
import matplotlib.dates as mdates
import matplotlib.pyplot as plt
from matplotlib.ticker import PercentFormatter
import pandas as pd
DIRECTORY = Path("/mnt/data")
TICKERS = ("NVDA", "MSFT", "AAPL", "GOOG")
COLORS = ("#007F65", "#245ABA", "#7750B4", "#BC5812")
def main():
"""Read the closing prices, calculate gains, and save the chart."""
closes = pd.read_csv(
DIRECTORY / "yahoo_finance_closes.csv", index_col="Date", parse_dates=True
).sort_index()
baseline = closes.loc["2025-12-31"]
gains = closes.loc["2026"].div(baseline).sub(1).mul(100)
fig, ax = plt.subplots(figsize=(11, 6), dpi=180)
fig.subplots_adjust(left=0.095, right=0.86, top=0.80, bottom=0.16)
fig.text(0.095, 0.94, "2026 YTD stock gains", fontsize=24, weight="bold")
last_day = gains.index[-1]
fig.text(
0.095, 0.895,
f"Daily change from the Dec 31, 2025 close through {last_day:%b %d, %Y}",
fontsize=11, color="#475569",
)
for ticker, color in zip(TICKERS, COLORS):
values = gains[ticker]
ax.plot(values.index, values, color=color, lw=1.8, label=ticker)
ax.scatter(last_day, values.iloc[-1], color=color, s=24, zorder=4)
ax.annotate(
f"{ticker} {values.iloc[-1]:+.1f}%",
(last_day, values.iloc[-1]), xytext=(8, 0), textcoords="offset points",
va="center", color=color, fontsize=9.5, weight="bold",
)
ax.axhline(0, color="#64748B", lw=0.9)
ax.set(xlabel="Day", ylabel="YTD Gain %", xlim=(pd.Timestamp("2026-01-01"), last_day))
ax.xaxis.set_major_locator(mdates.MonthLocator())
ax.xaxis.set_major_formatter(mdates.DateFormatter("%b"))
ax.yaxis.set_major_formatter(PercentFormatter(xmax=100, decimals=0))
ax.set_axisbelow(True)
ax.grid(axis="y", color="#E2E8F0", linewidth=0.8)
ax.spines[["top", "right", "left"]].set_visible(False)
ax.spines["bottom"].set_color("#CBD5E1")
ax.tick_params(length=0, pad=6, labelcolor="#334155")
fig.text(0.095, 0.045, "Source: Yahoo Finance · adjusted closing prices",
fontsize=9, color="#475569")
assert len(gains) > 200 and gains.index.is_unique
assert not gains.isna().any().any()
assert {line.get_label() for line in ax.lines[:-1]} == set(TICKERS)
assert (ax.get_xlabel(), ax.get_ylabel()) == ("Day", "YTD Gain %")
fig.savefig(DIRECTORY / "ytd_stock_gains.png", facecolor="white")
plt.close(fig)
if __name__ == "__main__":
main()
Code Writer The plot shows daily YTD gains for NVDA, MSFT, AAPL, and GOOG through November 20, 2026, relative to their December 31, 2025 adjusted closing prices.
Code Reviewer
The non-empty plot shows daily 2026 YTD gains for NVDA, MSFT, AAPL, and GOOG through November 20. It uses the requested axis labels, Day and YTD Gain %, and is saved as ytd_stock_gains.png. The readable plotting code includes a module docstring and calculates gains from the saved Yahoo Finance closing prices using December 31, 2025 as the baseline.
Minor suggestion: Add a small right margin inside the axes so the final-day markers aren’t clipped.
VERDICT: APPROVED